Prisma 6.7.0 error with better-auth
I upgrade to Prisma 6.7.0 and use the new rustless feature, but I keep getting this error now with better-auth. Any ideas?
file:///Users/salvatorenoto/Developer/Apps/rent-tracker/node_modules/@prisma/client/runtime/client.mjs: Invalid source map. Only conformant source maps can be used to find the original code. Cause: TypeError [ERR_INVALID_ARG_TYPE]: The "payload" argument must be of type object. Received null
2025-05-01T03:33:00.606Z ERROR [Better Auth]: INTERNAL_SERVER_ERROR [Error [PrismaClientKnownRequestError]:
Invalid `db[model].findFirst()` invocation in
/Users/salvatorenoto/Developer/Apps/rent-tracker/.next/server/chunks/node_modules_better-auth_dist_4791b761._.js:3456:44
3453 if (!db[model]) {
3454 throw new __TURBOPACK__imported__module__$5b$project$5d2f$node_modules$2f$better$2d$auth$2f$dist$2f$shared$2f$better$2d$auth$2e$DdzSJf$2d$n$2e$mjs__$5b$app$2d$route$5d$__$28$ecmascript$29$__["B"](`Model ${model} does not exist in the database. If you haven't generated the Prisma client, you need to run 'npx prisma generate'`);
3455 }
→ 3456 return await db[model].findFirst(
self-signed certificate in certificate chain] {
code: 'SELF_SIGNED_CERT_IN_CHAIN',
meta: [Object],
clientVersion: '6.7.0'
}
GET /api/auth/organization/get-full-organization 401 in 1561ms
file:///Users/salvatorenoto/Developer/Apps/rent-tracker/node_modules/@prisma/client/runtime/client.mjs: Invalid source map. Only conformant source maps can be used to find the original code. Cause: TypeError [ERR_INVALID_ARG_TYPE]: The "payload" argument must be of type object. Received null
2025-05-01T03:33:00.735Z ERROR [Better Auth]: INTERNAL_SERVER_ERROR [Error [PrismaClientKnownRequestError]:
Invalid `db[model].findFirst()` invocation in
/Users/salvatorenoto/Developer/Apps/rent-tracker/.next/server/chunks/node_modules_better-auth_dist_4791b761._.js:3456:44
3453 if (!db[model]) {
3454 throw new __TURBOPACK__imported__module__$5b$project$5d2f$node_modules$2f$better$2d$auth$2f$dist$2f$shared$2f$better$2d$auth$2e$DdzSJf$2d$n$2e$mjs__$5b$app$2d$route$5d$__$28$ecmascript$29$__["B"](`Model ${model} does not exist in the database. If you haven't generated the Prisma client, you need to run 'npx prisma generate'`);
3455 }
→ 3456 return await db[model].findFirst(
self-signed certificate in certificate chain] {
code: 'SELF_SIGNED_CERT_IN_CHAIN',
meta: [Object],
clientVersion: '6.7.0'
}
file:///Users/salvatorenoto/Developer/Apps/rent-tracker/node_modules/@prisma/client/runtime/client.mjs: Invalid source map. Only conformant source maps can be used to find the original code. Cause: TypeError [ERR_INVALID_ARG_TYPE]: The "payload" argument must be of type object. Received null
2025-05-01T03:33:00.606Z ERROR [Better Auth]: INTERNAL_SERVER_ERROR [Error [PrismaClientKnownRequestError]:
Invalid `db[model].findFirst()` invocation in
/Users/salvatorenoto/Developer/Apps/rent-tracker/.next/server/chunks/node_modules_better-auth_dist_4791b761._.js:3456:44
3453 if (!db[model]) {
3454 throw new __TURBOPACK__imported__module__$5b$project$5d2f$node_modules$2f$better$2d$auth$2f$dist$2f$shared$2f$better$2d$auth$2e$DdzSJf$2d$n$2e$mjs__$5b$app$2d$route$5d$__$28$ecmascript$29$__["B"](`Model ${model} does not exist in the database. If you haven't generated the Prisma client, you need to run 'npx prisma generate'`);
3455 }
→ 3456 return await db[model].findFirst(
self-signed certificate in certificate chain] {
code: 'SELF_SIGNED_CERT_IN_CHAIN',
meta: [Object],
clientVersion: '6.7.0'
}
GET /api/auth/organization/get-full-organization 401 in 1561ms
file:///Users/salvatorenoto/Developer/Apps/rent-tracker/node_modules/@prisma/client/runtime/client.mjs: Invalid source map. Only conformant source maps can be used to find the original code. Cause: TypeError [ERR_INVALID_ARG_TYPE]: The "payload" argument must be of type object. Received null
2025-05-01T03:33:00.735Z ERROR [Better Auth]: INTERNAL_SERVER_ERROR [Error [PrismaClientKnownRequestError]:
Invalid `db[model].findFirst()` invocation in
/Users/salvatorenoto/Developer/Apps/rent-tracker/.next/server/chunks/node_modules_better-auth_dist_4791b761._.js:3456:44
3453 if (!db[model]) {
3454 throw new __TURBOPACK__imported__module__$5b$project$5d2f$node_modules$2f$better$2d$auth$2f$dist$2f$shared$2f$better$2d$auth$2e$DdzSJf$2d$n$2e$mjs__$5b$app$2d$route$5d$__$28$ecmascript$29$__["B"](`Model ${model} does not exist in the database. If you haven't generated the Prisma client, you need to run 'npx prisma generate'`);
3455 }
→ 3456 return await db[model].findFirst(
self-signed certificate in certificate chain] {
code: 'SELF_SIGNED_CERT_IN_CHAIN',
meta: [Object],
clientVersion: '6.7.0'
}
1 Reply
can you show me your prisma schema file and your prisamc client config along with your auth config