P
Prisma5mo ago
salzar

Generating prisma to generated folder results in duplicate schema errors

This is driving me nuts, as you can see generated create another copy of my prisma schema and it results in a bunch of errors like in the pictures. Is there an easy solve, and also, even if Im bringing my own db, cna I used --no-engine flag? My currently not using the --no-engine flag.
No description
No description
5 Replies
Prisma AI Help
Prisma AI Help5mo ago
You're in no rush, so we'll let a dev step in. Enjoy your coffee, or drop into #ask-ai if you get antsy for a second opinion!
salzar
salzarOP5mo ago
@Prisma AI Help Can you answer this?
Nurul
Nurul5mo ago
Hey! You seem to be using prisma-client-js generator, can you try using the new prisma-client generator instead and check if you get the same errors?
salzar
salzarOP5mo ago
I have been switching back and forth, each giving me its own unique errors. I will try switching again and showing the errors here Also I am using zod-prisma-types and I don't think it plays well with the new engine So i switched and everything seems okay with types and such except I get a successful build but with these messages in the build
✓ Compiled successfully in 18.0s
✓ Linting and checking validity of types
Collecting page data ..[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
Collecting page data ...[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
✓ Collecting page data
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
✓ Generating static pages (50/50)
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
✓ Collecting build traces
✓ Finalizing page optimization

Route (app) Size First Load JS
┌ ○ / 7.74 kB 168 kB
├ ○ /_not-found 989 B 103 kB
├ ƒ /accept-invitation/[id] 2.13 kB 227 kB
├ ○ /admin 15.4 kB 288 kB
├ ƒ /api/auth/[...all] 178 B 102 kB
├ ƒ /api/chat 178 B 102 kB
├ ƒ /api/chat/real-estate 178 B 102 kB
├ ƒ /api/novu 178 B 102 kB
├ ƒ /api/workflows/generate-report 178 B 102 kB
├ ○ /apps/register 3.29 kB 225 kB
├ ● /auth/[pathname] 3.27 kB 323 kB
├ ├ /auth/accept-invitation
├ ├ /auth/api-keys
├ ├ /auth/callback
├ └ [+14 more paths]
├ ƒ /dashboard 4.23 kB 360 kB
├ ƒ /dashboard/accounting 310 B 425 kB
├ ƒ /dashboard/calendar 5.98 kB 252 kB
├ ƒ /dashboard/contacts 330 B 425 kB
├ ƒ /dashboard/contacts/[id] 4.44 kB 360 kB
├ ƒ /dashboard/contacts/form 13 kB 213 kB
├ ƒ /dashboard/leases 330 B 425 kB
├ ƒ /dashboard/leases/form 9.87 kB 215 kB
✓ Compiled successfully in 18.0s
✓ Linting and checking validity of types
Collecting page data ..[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
Collecting page data ...[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
✓ Collecting page data
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
✓ Generating static pages (50/50)
[Error [PrismaClientKnownRequestError]: 404 Not Found] {
code: 'P6000',
meta: {},
clientVersion: '6.12.0'
}
✓ Collecting build traces
✓ Finalizing page optimization

Route (app) Size First Load JS
┌ ○ / 7.74 kB 168 kB
├ ○ /_not-found 989 B 103 kB
├ ƒ /accept-invitation/[id] 2.13 kB 227 kB
├ ○ /admin 15.4 kB 288 kB
├ ƒ /api/auth/[...all] 178 B 102 kB
├ ƒ /api/chat 178 B 102 kB
├ ƒ /api/chat/real-estate 178 B 102 kB
├ ƒ /api/novu 178 B 102 kB
├ ƒ /api/workflows/generate-report 178 B 102 kB
├ ○ /apps/register 3.29 kB 225 kB
├ ● /auth/[pathname] 3.27 kB 323 kB
├ ├ /auth/accept-invitation
├ ├ /auth/api-keys
├ ├ /auth/callback
├ └ [+14 more paths]
├ ƒ /dashboard 4.23 kB 360 kB
├ ƒ /dashboard/accounting 310 B 425 kB
├ ƒ /dashboard/calendar 5.98 kB 252 kB
├ ƒ /dashboard/contacts 330 B 425 kB
├ ƒ /dashboard/contacts/[id] 4.44 kB 360 kB
├ ƒ /dashboard/contacts/form 13 kB 213 kB
├ ƒ /dashboard/leases 330 B 425 kB
├ ƒ /dashboard/leases/form 9.87 kB 215 kB
Ramparts
Ramparts5mo ago
simple fix here: do not generate into the same folder as the .schema file. instead, generate up a level ("../generated..." )

Did you find this page helpful?