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

Add support of Pydantic 2.10 #10

Merged
merged 4 commits into from
Jan 7, 2025
Merged

Conversation

candleindark
Copy link
Member

This PR closes #9.

This is put in to support different
version of Pydantic
@yarikoptic
Copy link
Member

@candleindark do you see how to bring this PR to the final version?

@candleindark
Copy link
Member Author

Yes, I see how. I am currently working on improving the generation of https://github.com/candleindark/validation-diff-reports?tab=readme-ov-file so that it will actually have a meaningful summary (handling the "what are those 'null null null' and "$insert"" as well).

As far as the translation goes, we don't need to have Pydantic 2.10. It is just that Pydantic modifies its core schema with every one or two patch versions. But if you want to have this completed first, let me know and I will work on it first.

@yarikoptic
Copy link
Member

As far as the translation goes, we don't need to have Pydantic 2.10.

we don't until some of our down stream projects decides that 2.10 must be their minimally supported version for some reason (e.g. fixing some issue). That is why we should always strive to avoid such specification of demanding older version, and if introduced as a temporary workaround -- address it promptly.

re diff reports: Remember also that for validation the main goal is a result of figuring out if there is anything to do based on our dandisets, not really establishing overall framework which we might not use much again. So let's summarize what we learned on current state of those diffs and what to be done to dandi-schema or translation.

To bring the disabling of the tests with
the aind package
This removes the temporary version restriction on Pydantic
put in by PR dandi#11
Conditionally on Pydantic>=2.10 for support of
the newly added `core_schema.InvalidSchema` in
Pydantic 2.10
@candleindark candleindark marked this pull request as ready for review January 7, 2025 22:21
@candleindark candleindark merged commit ee6693e into dandi:main Jan 7, 2025
4 checks passed
@candleindark candleindark deleted the pydantic-2_10 branch January 7, 2025 22:25
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.

Provide support of Pydantic 2.10
2 participants