Update dependency pydantic to v2.5.0 #251
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
2.4.2
->2.5.0
Release Notes
pydantic/pydantic (pydantic)
v2.5.0
Compare Source
GitHub release
The code released in v2.5.0 is functionally identical to that of v2.5.0b1.
What's Changed
Packaging
pyright==1.1.335
by @Viicos in #8075New Features
ValidationError
errors by @adriangb in #7806__doc__
argument increate_model()
by @chris-spann in #7863regex_engine
flag - meaning you can use with the Rust or Python regex libraries in constraints by @utkini in #7768ComputedFieldInfo
by @alexmojaki in #7889ruff
formatter by @Luca-Blight in #7930validation_error_cause
to config by @zakstucke in #7626CallableDiscriminator
andTag
by @dmontagu in #7983examples
andjson_schema_extra
to@computed_field
by @alexmojaki in #8013JsonValue
type by @dmontagu in #7998str
as argument toDiscriminator
by @dmontagu in #8047SchemaSerializer.__reduce__
method to enable pickle serialization by @edoakes in pydantic/pydantic-core#1006Changes
ultra_strict
with new smart union implementation, the way unions are validated has changed significantly to improve performance and correctness, we have worked hard to absolutely minimise the number of cases where behaviour has changed, see the PR for details - by @davidhewitt in pydantic/pydantic-core#867extra='allow'
by @sydney-runkle in #7683Enum
types with no cases by @sydney-runkle in #7927Generic
beforeBaseModel
by @alexmojaki in #7891Performance
jiter
by @samuelcolvin in pydantic/pydantic-core#974__getattr__
for all package imports, improve import time by @samuelcolvin in #7947Fixes
mypy
issue with subclasses ofRootModel
by @sydney-runkle in #7677FieldInfo
when a forward ref gets evaluated by @dmontagu in #7698SecretStr
from JSON (regression in v2.4) by @sydney-runkle in #7729defer_build
behavior withTypeAdapter
by @sydney-runkle in #7736mypy
versions by @dmontagu in #7742TypeVar
handling when default is not set by @pmmmwh in #7719strict
onEnum
type fields by @sydney-runkle in #7761weakref.ref
instead of subclassing to fixcloudpickle
serialization by @edoakes in #7780model_post_init
in subclasses by @alexmojaki in #7775json_schema_extra
by @alexmojaki in #7803strict
specification forUUID
types by @sydney-runkle in #7865pydantic.Field(kw_only=True)
with inherited dataclasses by @PrettyWood in #7827validate_call
decorator for methods in classes with__slots__
by @sydney-runkle in #7883dataclasses.field
default by @hramezani in #7898importlib_metadata
on python 3.7 by @sydney-runkle in #7904|
operator (Union) in PydanticRecursiveRef by @alexmojaki in #7892display_as_type
forTypeAliasType
in python 3.12 by @dmontagu in #7929NotRequired
generics inTypedDict
by @sydney-runkle in #7932TypeAliasType
specifications produce different schema definitions by @alexdrydew in #7893PrivateAttr
is passed fromAnnotated
default position by @tabassco in #8004classmethod
instead ofclassmethod[Any, Any, Any]
by @Mr-Pepe in #7979Optional
field withvalidate_default
only performing one field validation by @sydney-runkle in pydantic/pydantic-core#1002definition-ref
bug withDict
keys by @sydney-runkle in pydantic/pydantic-core#1014bool
types withcoerce_numbers_to_str=True
by @sydney-runkle in pydantic/pydantic-core#1017NaN
in float and decimal constraints by @davidhewitt in pydantic/pydantic-core#1037lax_str
andlax_int
support for enum values not inherited from str/int by @michaelhly in pydantic/pydantic-core#1015Union
ofList
types by @sydney-runkle in pydantic/pydantic-core#1039max_digits
anddecimals
to pass if normalized or non-normalized input is valid by @sydney-runkle in pydantic/pydantic-core#1049ValidationError
messages by @Iipin in pydantic/pydantic-core#1050'-'
asdatetime
input by @davidhewitt in pydantic/speedate#52 & pydantic/pydantic-core#1060New Contributors
pydantic
pydantic-core
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Enabled.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.