`PrismaClientInitializationError: Prisma Client could not locate the Query Engine for runtime` error
I'm having an error when trying to bundle my application with ts up
7 Replies
The error is fixed when copying the
libquery_engine-darwin-arm64.dylib.node
file right next to my bundle
I need to do this manually, are there any workarounds I can make for this?did you find a resolution for this?
@bill92
Did you?
did anyone else find a solution to this? i dont want a manual workaround. the nextjs workaround webpack solution also doesn't work (and also i don't want to use webpack). every thread i find related to this has ended with zero real solutions @Nurul
Are you also trying to bundle the application with
ts up
?
Is this happening on latest prisma version (6.6.0)?Latest version, not ts up. I moved some stuff around and reconfigured the next.config.js and it appears to work in prod now.
Honestly prisma-client will be the solution to this, the node_modules issues in monorepo can be a pain so I’m excited to see this in early access! https://x.com/prisma/status/1910649283159986273?s=46
Prisma (@prisma) on X
💡 In v6.6.0, we launched a new generator called `prisma-client` in Early Access:
🌟 Requires an `output` path (no more “magic” generation into `node_modules`)
✅ Supports ESM & CommonJS via `moduleFormat`
👾 Outputs plain TS that's bundled just like the rest of your code

X
I am glad to hear that you were able to make it work.
Thank you so much for your kind words 🙂 We are looking forward to make prisma-client the default provider with Prisma 7