Note
Addendum: 2.11 introduced a small behavior change with Final
attributes with an underscore:
class Model(BaseModel): _var: Final[int] = 1
In 2.10, _var
would be considered as a class variable, but as a private attribute in 2.11.
As documented in the blog post, you can make use of ClassVar
instead of Final
to keep it as a class variable.
check_pydantic_core_version()
function by @Viicos in #11324greenlet
development dependency by @Viicos in #11351typing-inspection
library by @Viicos in #11479pydantic-core
to v2.31.1
by @sydney-runkle in #11526default_factory_takes_validated_data
property to FieldInfo
by @Viicos in #11034type[]
by @Viicos in #11088create_model
field definitions format by @Viicos in #11032model_fields
and model_computed_fields
on instances by @Viicos in #11169GenerateSchema
class by @sydney-runkle in #10846get_type_ref
by @Viicos in #10863pydantic-core
core schema validation by @sydney-runkle in #11271FieldInfo
annotations if required during schema building by @Viicos in #10769__setattr__
performance of Pydantic models by caching setter functions by @MarkusSintonen in #10868_typing_extra
module by @Viicos in #11255CoreConfig
instance by @sydney-runkle in #11384pydantic-core
and thus use SchemaValidator
and SchemaSerializer
caching by @sydney-runkle in #11402TypeAdapter
instance repr by @sydney-runkle in #10872TypeAdapter
by @Viicos in #10893Literal
values if using PEP 695 type aliases by @Viicos in #11114__subclasscheck__
on ModelMetaclass
to avoid memory leak and performance issues by @Viicos in #11116_extract_get_pydantic_json_schema()
parameter by @Viicos in #11155Annotated
form by @Viicos in #11109deprecated_instance_property
warning by @Viicos in #11200WithJsonSchema
schema to avoid sharing mutated data by @thejcannon in #11014CoreMetadata
definition by @Viicos in #11216_Definitions
class by @Viicos in #11208root
type in the mypy plugin by @Viicos in #11212use_attribute_docstrings
by @Viicos in #11246decimal_places_validator
by @misrasaurabh1 in #11281validation_alias
in the mypy plugin by @Viicos in #11295"examples"
keys by @Viicos in #11305GenerateJsonSchema.literal_schema()
implementation by @misrasaurabh1 in #11321ClickHouseDsn
by @Maze21127 in #11319Decimal
instances by @Viicos in #11350additionalProperties: True
for arbitrary dictionary schemas by @austinyu in #11392fallback
parameter in serialization methods by @Viicos in #11398Sequence
types by @sydney-runkle in #11435__get_validators__
on classes where __get_pydantic_core_schema__
is also defined by @tlambert03 in #11444validate_by_name
to True
when validate_by_alias
is False
by @sydney-runkle in #11503Any
when synthesizing BaseSettings.__init__
signature in the mypy plugin by @Viicos in #11497ValueError
on year zero by @davidhewitt in pydantic/pydantic-core#1583dataclass
InitVar
shouldn't be required on serialization by @sydney-runkle in pydantic/pydantic-core#1602Full Changelog: v2.10.6...v2.11.0b1
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4