Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pydantic v2 support #91

Open
wants to merge 9 commits into
base: master
Choose a base branch
from

Conversation

Gallaecio
Copy link
Member

Continuation of #86 with the following additional changes:

  • The itemadapter API remains backward compatible (no separate PydanticV1Adapter class).
  • Add extras for attrs, pydantic and scrapy, so that users can make sure they get the right versions of those packages (and potential future dependencies related to them) when installing them for itemadapter.
  • Create separate tox envs for attrs, pydantic, scrapy, and combining all of them. Test with minimum and latest versions. For Pydantic, also test with the latest 1.x version. The regular tox envs do not install those dependencies.
  • Create a separate docs tox env to check the README code.
  • Updated the README to reflect the output with the latest pydantic version.
  • Replace the README ADAPTER_CLASSES example that requires cloning the repo (uses tests/ code) with one that installs a third-party package instead (zyte-common-items). I think the code is more readable, and it’s good to point to a real example of a custom adapter.

Resolves #72, closes #76, closes #86.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Pydantic 2 released
5 participants