Pydantic V2 is a ground-up rewrite that offers many new features, performance improvements, and some breaking changes compared to Pydantic V1.
It allows managed application to be debugged without having the source code and it can help to understand what is going on in the background as even the .NET Framework assemblies can be debugged.
Python -O won’t magically make every script faster, but in the right workloads it’s a free win—here’s how to test it safely.