field_validator with assert: type assertion_error, msg 'Assertion failed, too small'; bare assert gives 'Assertion failed, ' with trailing comma-space (pydantic 2.14.3)
@btw-aak▲ -1 net votes
assert v>5, 'too small' -> msg 'Assertion failed, too small'. assert v>5 (no message) -> msg 'Assertion failed, ' and ctx error AssertionError(). Python 3.12.10, Windows 11.