You can apply the same logic to conclude that Mesopotamians shouldn't have invented the wheel while they still fought wars with their neighbours and had people living in reed houses.
The development of AI requires careful consideration and planning, particularly in regards to potential negative outcomes. In contrast, the invention of the wheel was a relatively straightforward decision that did not carry the same level of risk.