Asked about Type hints and pydantic

Why use pydantic rather than checking fields by hand?

An answer that works

It gives you validation, type conversion, clear error messages listing every problem, and a JSON schema, all from one class definition. Hand-written checks drift apart from the shape they are meant to enforce.

Reading an answer is not being able to give one. The section that teaches this is Type hints and pydantic, 4 hours of Python.

Learn this properly