Thanks for another great Pydantic tutorial Lyle! 🙏😀 Great tip about possible undesired conversion behaviour at 8:38 and the order of union types. I'm looking forward to the next one.
This is the best explanation. Your tutorial is very helpful for me to understand the topic clearly. I would love to watch a series of FastAPI with Pydantic from you.
5:40 - please don't assign a list (or any mutable type) as a default value. Even if Pydantic probably handles this gracefully, it is a trap for users of the class if they construct Student objects and use append to build the list of modules. Use the field helper class instead.