I am no fan of AI, but I can maybe help ease your mind a bit on this. I know almost nowt about water supplies, but I do know how such automation works. Apologies if this is stuff you know.
Systems such as water supply do have a top level PC control system, and yes they can be hacked and shut down, but they can't be "fiddled with", for example to poison the water. Because the top level control does the monitoring and has limited control, but there are loads of subsystems, not PC controlled. They are PLC controlled. And in a well-designed system, that is where the safety interlocks are. And they can't be over-ridden by the master control. They need someone to physically go in and flick a switch. before they can be reprogrammed. In a different language.
When we have had water scares in the past, and boil water warnings etc, that comes from physical things. A broken pipe, or an operator physically pouring the wrong treatment chemical into the wrong tank at the treatment station.
Moving from water that I do not know, to factory automation, that I do know. The terminator "rise of the Machines" scifi scenario where a computer program takes over a factory and makes "killer robots" can't happen. Because there is a massive number of separate systems with no reprogramming interface between them. These robot arms for example are manually programmed by someone with a programming device. The next level control up, the module PLC can only tell the robot arm to go, or stop And the robot can pass error signals back.. It cant reprogram it. They use a different language. And the next level up from the PLC, is the same. Different language and limited interface. Add in cost of course. The factories in these films would simply be too expensive. Because why would a company spend loads of money a system giving the master control direct programming connections to a motor control, for example, when there is no cost effective reason for doing so ? Yes, I know PLCs can be programmed remotely, but it needs people at the PLC side to flick a switch.
And then there is the estop system. Push that red mushroom button, and by law that is a physical mechanical switch arrangement that needs physical input to reset.