flâneur — a map of the web's best reading

Welcome to Pydantic - Pydantic

docs.pydantic.dev · 1,011 words · saved by 1 readers

Fast and extensible, Pydantic plays nicely with your linters/IDE/brain. Define how data should be in pure, canonical Python 3.8+; validate it with Pydantic. Migrating to Pydantic V2 Using Pydantic V1? See the Migration Guide for notes on upgrading to Pydantic V2 in your applications! Why is Pydantic named the way it is? The name "Pydantic" is a portmanteau of "Py" and "pedantic." The "Py" part indicates that the library is associated with Python, and "pedantic" refers to the library's meticulous approach to data validation and type enforcement. Combining these elements, "Pydantic" describes our Python library that provides detail-oriented, rigorous data validation. We’re aware of the irony that Pydantic V1 was not strict in its validation, so if we're being pedantic, "Pydantic" was a misnomer until V2 😉. Installing Pydantic is as simple as: pip install pydantic To see Pydantic at work, let's start with a simple example, creating a custom class that inherits from BaseModel: If validati

Welcome to Pydantic | Pydantic Docs Skip to content Get Started Welcome to Pydantic Why use Pydantic Help with Pydantic Installation Migration Guide Version Policy Contributing Changelog Concepts Models Fields JSON Schema JSON Types Unions Alias Configuration Serialization Validators Dataclasses Forward Annotations Strict Mode Type Adapter Validation Decorator Conversion Table Settings Management Performance Experimental API Documentation Pydantic BaseModel RootModel Pydantic Dataclasses TypeAdapter Validate Call Fields Aliases Configuration JSON Schema Errors Functional Validators Functional

Explore this link on the map →

related reading