Fattrick Collins
PPrisma
•Created by Fattrick Collins on 11/25/2024 in #help-and-questions
creation of new user failed and exited an error in vercel logs for my project
In the creation of new users I made use of better auth for authentication and the creation of a new user in my nextjs project which I integrated with prisma as my ORM with supabase as my database............. this arrangement however performs the creation of the new user in development however after deploying to vercel and performing the same authentication of new users it throws this error which indicates that the new user cannot be created and i don't seem to know why it doesn't work in deployment where i have added the environemt variables required by prisma like the DATABASE_URL and the DIRECT_URL needed by prisma to connect to my supabase database and this connnection worked fine
The error from vercel logs upon creation of new users:
[Better Auth] ERROR
Invalid prisma.user.findFirst() invocation: The table public.User does not exist in the current database. Invalid prisma.user.findFirst() invocation:
The table public.User does not exist in the current database. at $n.handleRequestError (node_modules/@prisma/client/runtime/library.js:121:7315) at $n.handleAndLogRequestError (node_modules/@prisma/client/runtime/library.js:121:6623) at $n.request (node_modules/@prisma/client/runtime/library.js:121:6307) at async l (node_modules/@prisma/client/runtime/library.js:130:9633) at async Object.findOne (.next/server/app/api/auth/[...all]/route.js:2689:39615) at async Object.findUserByEmail (.next/server/app/api/auth/[...all]/route.js:85:21632) at async .next/server/app/api/auth/[...all]/route.js:85:1052 at async i (.next/server/app/api/auth/[...all]/route.js:1:66010) at async s.<computed> (.next/server/app/api/auth/[...all]/route.js:85:6930) at async s (.next/server/app/api/auth/[...all]/route.js:1:70740) @everyone
Invalid prisma.user.findFirst() invocation: The table public.User does not exist in the current database. Invalid prisma.user.findFirst() invocation:
The table public.User does not exist in the current database. at $n.handleRequestError (node_modules/@prisma/client/runtime/library.js:121:7315) at $n.handleAndLogRequestError (node_modules/@prisma/client/runtime/library.js:121:6623) at $n.request (node_modules/@prisma/client/runtime/library.js:121:6307) at async l (node_modules/@prisma/client/runtime/library.js:130:9633) at async Object.findOne (.next/server/app/api/auth/[...all]/route.js:2689:39615) at async Object.findUserByEmail (.next/server/app/api/auth/[...all]/route.js:85:21632) at async .next/server/app/api/auth/[...all]/route.js:85:1052 at async i (.next/server/app/api/auth/[...all]/route.js:1:66010) at async s.<computed> (.next/server/app/api/auth/[...all]/route.js:85:6930) at async s (.next/server/app/api/auth/[...all]/route.js:1:70740) @everyone
7 replies