I don't understand, how can you not fault AI for generating code that can't handle unexpected data gracefully?
If you'd write the code yourself, you'd be much more likely to remember to handle those cases as well.
If you'd write the code yourself, you'd be much more likely to remember to handle those cases as well.