This seems like a scenario that only happens in tests. I've not seen an error being set in this fashion, as every other part of the code expects the errors to be represented as an hash of attributes which contain an array of messages.

This and the test below were the only two failing tests under the activemodel directory.