Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Update pydantic usage before 3.0 #652

@skrawcz

Description

@skrawcz

Need to drop usage of model_fields:

Current behavior

/.../python3.11/site-packages/burr/integrations/pydantic.py:37: PydanticDeprecatedSince211: Accessing the 'model_fields' attribute on the instance is deprecated. Instead, you should access this attribute from the model class. Deprecated in Pydantic V2.11 to be removed in V3.0.
keys = model.model_fields.keys()

Steps to replicate behavior

  1. Use pydantic 2.11+
  2. You'll see this warning.

Library & System Information

python 3.11
pydantic 2.11

Expected behavior

we dont see this warning and things work.

Additional context

We should set a minimum pin once we do this change.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions