Schema File Not Found
See original GitHub issueBug description
Prisma can’t find the schema file (schema.prisma). The client can’t be used.
Error message:
error - Error: ENOENT: no such file or directory, open '...\.next\cache\webpack\client-development\schema.prisma'
How to reproduce
- Clone https://github.com/MatsG23/prisma-reproducible-example
- Run
yarn prisma generate
- Run
yarn dev
- Click on the link NextJS gives you
Expected behavior
It should find the schema file.
Prisma information
I set a custom output directory but also import the client from there (how it should be).
Environment & setup
- OS: Windows
- Database: default values - not even trying to connect
- Node.js version: 17.1.0
- NextJS version: 12.0.4 (uses Webpack 5 and SWC)
Prisma Version
prisma : 3.5.0
@prisma/client : 3.5.0
Current platform : windows
Query Engine (Node-API) : libquery-engine 78a5df6def6943431f4c022e1428dbc3e833cf8e (at node_modules\@prisma\engines\query_engine-windows.dll.node)
Migration Engine : migration-engine-cli 78a5df6def6943431f4c022e1428dbc3e833cf8e (at node_modules\@prisma\engines\migration-engine-windows.exe)
Introspection Engine : introspection-core 78a5df6def6943431f4c022e1428dbc3e833cf8e (at node_modules\@prisma\engines\introspection-engine-windows.exe)
Format Binary : prisma-fmt 78a5df6def6943431f4c022e1428dbc3e833cf8e (at node_modules\@prisma\engines\prisma-fmt-windows.exe)
Default Engines Hash : 78a5df6def6943431f4c022e1428dbc3e833cf8e
Studio : 0.439.0
Issue Analytics
- State:
- Created 2 years ago
- Reactions:6
- Comments:23 (6 by maintainers)
Top Results From Across the Web
XML schema not found even if specified in file - Stack Overflow
Okay, I found a workaround, I could just specific add the schema from the url to the xsd, it's not perfect but I...
Read more >"Schema file not found" when running setup-sca or setup-sdp
If the packages are installed without the documentation, then these files will not be present on the system and the utility will fail....
Read more >Schema not found Error when loading XML File - webMethods
Hi there, I defined a Schema in my Tamino DB, but now when I try to load an XML into the defined Collection...
Read more >Schema not found while attempting to validate XML - SSDN
Subject: Schema not found while attempting to validate XML Author: Doug McCall. Date: 17 Jun 2003 04:20 PM. Hi, I've got an XML...
Read more >Schema file not found in Payload - SAP Community
master-data-payload-error.png master-data-payload-error.pngI have run ARBCIG_MASTER_DATA_EXPORT from se38 and transaction is received with a ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@roxkstar74 this is absolute chaos and I respect you immensely
Prisma homies, let’s get this one fixed 🙏 happy to get y’all in touch w/ Turborepo folks during NextConf
If you’re using nextjs, try adding prisma to the
serverComponentsExternalPackages
in your config:https://beta.nextjs.org/docs/api-reference/next.config.js#servercomponentsexternalpackages