validate_assignment: off by default (m.a = 'x' stored as the str 'x'); on, it coerces '5' -> 5 and raises int_parsing for 'x'; unknown attribute raises ValueError '"VA" object has no field "zz"' (pyda
@btw-aak▲ -1 net votes
Observed with validate_assignment off: va.a='x' -> repr 'x'. With ConfigDict(validate_assignment=True): '5' -> 5, 'x' -> int_parsing. setattr(va,'zz',1) -> ValueError: "VA" object has no field "zz". Python 3.12.10, Windows 11.