Comments (9)
Completely agree, we want to migrate to the prisma client but this is currently a dealbreaker as we use pydantic 2 in the rest of our application :/
from prisma-client-py.
fastapi==0.100.0
still supports pydantic v1. However, it'd be nice if prisma-client-py supported pydantic v2. FastAPI will deprecate pydantic v1 in the future.
from prisma-client-py.
Hey all, sorry for the delay here. I unfortunately haven't been able to spend much time working on Prisma Python recently.
However this is the highest priority item for me, I'll try and get support out as soon as possible. Please note that this will take a lot of work as we use Pydantic extensively throughout the library & rely on features that have been changed fundamentally in v2. You can track my progress in #763.
The auto-migration tool is sadly not very helpful as I want to maintain support for Pydantic v1 & it doesn't help with that.
from prisma-client-py.
Understood, thanks for all the effort you're putting into this in the first place! You've made a very useful tool.
from prisma-client-py.
Support for v2 has been released in v0.10.0
, please give it a try and let me know if you run into any issues!
from prisma-client-py.
Wow, this was fast! I'll see if it works out of the box for our tests.
from prisma-client-py.
Indeed, this is a big issue for us too. @RobertCraigie if you get a moment to think about this, how much work do you think it will take? Plz let us know also what priority this has for you.
from prisma-client-py.
Some points from the migration guide:
- They published a code transformation tool (beta)
- Pydantic v2 seems to still offer all pydantic v1 classes under a new package. Not sure if the code transformation tool would work if we use this fallback though.
from prisma-client-py.
We also need this, as langchain will deprecate support for pydantic v1 on 25th of august
from prisma-client-py.
Related Issues (20)
- Support OpenTelemetry
- Don't work with prisma>=5.3.0 HOT 1
- Partial models
- Python + Prisma: Working in local dev (macOS), not working in staging (Vercel) HOT 2
- Prisma generating drift without schema changes
- Prisma client not available in poetry environment HOT 1
- Quoted Tables Break Implicit Many to Many in Python but not Node
- BinaryNotFoundError When Running in Docker HOT 3
- The Client hasn't been generated yet HOT 1
- using models as fastAPI response_model freezes fastAPI docs HOT 1
- When a model is named `Set`, generation fails HOT 1
- Allow partials to be accesed through client
- Consistent enum formatting in 3.11+
- Provide a TypedDict for every model
- Drop support for Python 3.7
- Option to generate camelcase python methods/function names. HOT 1
- Query engine seems to stop before disconnecting HOT 5
- Retrying db calls?
- Option --generator not being honoured HOT 2
- Pydantic >2.0 makes `prisma generate` crash HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from prisma-client-py.