-
Notifications
You must be signed in to change notification settings - Fork 245
"error 3 validation errors for Prediction" when running "replicate.run()" #112
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
Comments
got the same error |
It should be the problem of updating the pydantic package to 2.0.Just reinstall version 1.9 will fix it. such as:
|
@SCUTlihaoyu This worked well. Thank you! |
Hi @waelmansourx. Thanks for reporting this. Apologies for the inconvenience. As @SCUTlihaoyu mentioned, these are due to breaking changes in Pydantic 2.0 which was released a few days ago. I'm looking into what it'd take to support both 1.x and 2.0. But in the meantime, pinning to 1.9 as @SCUTlihaoyu suggested should do the trick. |
@waelmansourx @Mig29github @SCUTlihaoyu I just released version 0.8.4, which pins Pydantic to 1.x. This should solve the immediate problem you encountered with Pydantic 2 incompatibility. As mentioned in #113, my goal is to update this library to support both Pydantic 1.x and 2.x in a future release. Please let me know if you have any other issues with this. Thanks! |
From https://pypi.org/project/pydantic/2.0/
|
Refs replicate#112 Signed-off-by: Simon Willison <[email protected]>
* Work with both Pydantic 1 and 2 Refs #112 Signed-off-by: Simon Willison <[email protected]> * Ignore type checking on pydantic import statements --------- Signed-off-by: Simon Willison <[email protected]> Co-authored-by: Mattt Zmuda <[email protected]>
@simonw Thanks for pointing that out, and for #121. Curious that this V1 shim doesn't seem to be mentioned anywhere on https://docs.pydantic.dev/latest/. |
* Work with both Pydantic 1 and 2 Refs replicate/replicate-python#112 Signed-off-by: Simon Willison <[email protected]> * Ignore type checking on pydantic import statements --------- Signed-off-by: Simon Willison <[email protected]> Co-authored-by: Mattt Zmuda <[email protected]>
Everytime I use this command, with any model
I recieve this error:
The text was updated successfully, but these errors were encountered: