-
Notifications
You must be signed in to change notification settings - Fork 121
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
FastAPI (v0.100.0) / Pydantic v2 incompatibility #539
Comments
Appreciate the honesty. What's the most recent working version of FastAPI? Update: I checked pydantic v1 with FastAPI 0.100.0 |
Yes you can use the latest FastAPI (v0.100.0) with Pydantic v1. fastapi = "0.100.0"
pydantaic = ">=1.10.2,<2.0"
redis-om = "0.1.3" |
I got similar error @ninoseki How can i handle if i use post method it gives me save is not working it's my first time of using redis plz help |
|
thanks @dgtlmonk ! It worked for me |
I'm sorry I think I made a mistake in #533.
I misunderstood that FastAPI (v0.100.0) has a compatibility in Pydantic v1 & v2 and it can use both versions as a response model & response body. But it doesn't.
For example, the following code fails because the latest FastAPI does not allow using Pydantic v1 as a response model & body class.
There is a workaround like the following.
But I think it's not good.
So it will be better to revert #533 if the FastAPI support has the high priority in this library. Again, sorry for my careless.
The text was updated successfully, but these errors were encountered: