Add warning when "alias" is set in ignored Annotated field by @nix010 in #9170
Support serialization of some serializable defaults in JSON schema by @sydney-runkle in #9624
Relax type specification for __validators__ values in create_model by @sydney-runkle in #9697
Breaking Change: Improve smart union matching logic by @sydney-runkle in pydantic/pydantic-core#1322
You can read more about our smart union matching logic here. In some cases, if the old behavior
is desired, you can switch to left-to-right mode and change the order of your Union members.
Performance
Internal Improvements
⚡️ Speed up _display_error_loc() by 25% in pydantic/v1/error_wrappers.py by @misrasaurabh1 in #9653
⚡️ Speed up _get_all_json_refs() by 34% in pydantic/json_schema.py by @misrasaurabh1 in #9650
⚡️ Speed up is_pydantic_dataclass() by 41% in pydantic/dataclasses.py by @misrasaurabh1 in #9652
⚡️ Speed up to_snake() by 27% in pydantic/alias_generators.py by @misrasaurabh1 in #9747
⚡️ Speed up unwrap_wrapped_function() by 93% in pydantic/_internal/_decorators.py by @misrasaurabh1 in #9727
Fixes
Replace __spec__.parent with __package__ by @hramezani in #9331
Add warning when "alias" is set in ignored Annotated field by @nix010 in #9170
Support serialization of some serializable defaults in JSON schema by @sydney-runkle in #9624
Relax type specification for __validators__ values in create_model by @sydney-runkle in #9697
Breaking Change: Improve smart union matching logic by @sydney-runkle in pydantic/pydantic-core#1322
You can read more about our smart union matching logic here. In some cases, if the old behavior
is desired, you can switch to left-to-right mode and change the order of your Union members.
Performance
Internal Improvements
⚡️ Speed up _display_error_loc() by 25% in pydantic/v1/error_wrappers.py by @misrasaurabh1 in #9653
⚡️ Speed up _get_all_json_refs() by 34% in pydantic/json_schema.py by @misrasaurabh1 in #9650
⚡️ Speed up is_pydantic_dataclass() by 41% in pydantic/dataclasses.py by @misrasaurabh1 in #9652
⚡️ Speed up to_snake() by 27% in pydantic/alias_generators.py by @misrasaurabh1 in #9747
⚡️ Speed up unwrap_wrapped_function() by 93% in pydantic/_internal/_decorators.py by @misrasaurabh1 in #9727
Fixes
Replace __spec__.parent with __package__ by @hramezani in #9331
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Bumps pydantic from 2.7.4 to 2.8.0.
Release notes
Sourced from pydantic's releases.
... (truncated)
Changelog
Sourced from pydantic's changelog.
... (truncated)
Commits
1609e2a
Prep for v2.8 release (#9806)411dfd8
👥 Update Pydantic People (#9803)e280663
Add Nested Model Field Validation Examples to Docs (#9735)a002e69
Fix Python version check for_eval_type
(#9781)e108fd1
Docs updates to prep for v2.8 (#9778)011d8b6
Fix documentation formatting (#9779)738b5d7
Add note about Pipeline API recommended usage (#9777)8a0f335
Document and testser_json_inf_nan='strings'
variant (#9771)764e148
Preparing for the v2.8.0b1 release! (#9776)fcd2010
validate_call
type params fix (#9760)Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase
.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show