Initial Checks
Description
Pydantic uses PEP 681's dataclass_transform for compatibility with static type checkers. One of the features described in PEP 681 is the ability to describe a set of custom "field specifier" classes. In an early version of PEP 681, these were specified using a parameter named field_descriptors, but based on feedback the parameter name was changed to field_specifiers for the final version of the PEP. Pydantic is still using the (now obsolete) parameter name.
See microsoft/pyright#3912 for details.
Example Code
No response
Python, Pydantic & OS Version
Python 3.11
Pydantic 1.10.2
Affected Components
Initial Checks
Description
Pydantic uses PEP 681's
dataclass_transformfor compatibility with static type checkers. One of the features described in PEP 681 is the ability to describe a set of custom "field specifier" classes. In an early version of PEP 681, these were specified using a parameter namedfield_descriptors, but based on feedback the parameter name was changed tofield_specifiersfor the final version of the PEP. Pydantic is still using the (now obsolete) parameter name.See microsoft/pyright#3912 for details.
Example Code
No response
Python, Pydantic & OS Version
Affected Components
.dict()and.json()construct(), pickling, private attributes, ORM mode