-
Notifications
You must be signed in to change notification settings - Fork 18
Update Pydantic usage for v2 compatibility #185
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
Conversation
|
Tests are failing as there's increased type specificity (particularly with numpy self-reporting types rather than pydantic choosing the type). These changes are work for both |
All changes are internal. The main changes are in prototypes and API errors. Prototypes now are created from dictionaries of tuples of (type, value). API errors are now a list of dictionaries, giving the type, location, error message, erroneous input, and a url to pydantic's website with more about the error.
|
For now, spacy is not compliant with pydantic v2. These changes will give some deprecation warnings in tests, but overall are v1 and v2 compatible. |
| python -m pip install xgboost | ||
| python -m pip install spacy | ||
| python -m pip install torch | ||
| python -m pip install statsmodels |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is effectively the same as python -m pip install -e ".[dev,all_models]", but Python 3.7 will not complete installation, ending in an OSError saying there is not enough space 😩 this is likely due to some pretty intense dependency resolution.
I'll likely want to rethink this strategy, but that can come in a separate PR.
| python -m pip install spacy | ||
| python -m pip install torch | ||
| python -m pip install statsmodels | ||
| python -m pip install typing_extensions==4.7.1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pinned due to fastapi requirements. fastapi/fastapi#9808
resolves #184