You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if i start my project i see Deprecationwarning about extra kwargs in Field declaration.
PydanticDeprecatedSince20: Extra keyword arguments on Fieldis deprecated and will be removed. usejson_schema_extra instead. Deprecated in Pydantic V2.0 to be removed in V3.0. See Pydantic V2 Migration Guide at https://errors.pydantic.dev/2.1.1/migration/
I can't made any suggestion about model of Field if i have more than 40 models.
I solve it in fields.py - added next code after 783 row:
783: if extra:
784: warn(str(extra), DeprecationWarning) # i add this warning to see deprecated extra kwargs.
785: warn('Extra keyword arguments on `Field` is .....', DeprecationWarning)
it helps me to migrate to V2 faster.
I think it should exists by default
Initial Checks
Description
if i start my project i see Deprecationwarning about extra kwargs in Field declaration.
PydanticDeprecatedSince20: Extra keyword arguments on
Fieldis deprecated and will be removed. use
json_schema_extrainstead. Deprecated in Pydantic V2.0 to be removed in V3.0. See Pydantic V2 Migration Guide at https://errors.pydantic.dev/2.1.1/migration/
I can't made any suggestion about model of Field if i have more than 40 models.
I solve it in fields.py - added next code after 783 row:
it helps me to migrate to V2 faster.
I think it should exists by default
Example Code
No response
Python, Pydantic & OS Version
Selected Assignee: @lig
The text was updated successfully, but these errors were encountered: