You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
prisma:info Starting a sqlite pool with 9 connections.
Error calling enhanced Prisma method `author.update`:
Invalid `prisma.post.deleteMany()` invocation:{ where: { AND: [ { id: { equals: 3 }, authorId: undefined~~~~~~~~~ }, { orgId: { equals: "org" } } ] }}Invalid value for argument `0`: explicitly `undefined` values are not allowed. at C:\Users\tomas\workspace\mindfuel\try-prisma-fastify\src\main.ts:23:25, at step (C:\Users\tomas\workspace\mindfuel\try-prisma-fastify\src\main.ts:33:23), at Object.next (C:\Users\tomas\workspace\mindfuel\try-prisma-fastify\src\main.ts:14:53), at fulfilled (C:\Users\tomas\workspace\mindfuel\try-prisma-fastify\src\main.ts:5:58) { name: 'PrismaClientValidationError', clientVersion: '6.1.0', internalStack: 'PrismaClientValidationError: \n' +'Invalid `prisma.post.deleteMany()` invocation:\n' +'\n' +'{\n' +' where: {\n' +' AND: [\n' +' {\n' +' id: {\n' +' equals: 3\n' +' },\n' +' authorId: undefined\n' +' ~~~~~~~~~\n' +' },\n' +' {\n' +' orgId: {\n' +' equals: "org"\n' +' }\n' +' }\n' +' ]\n' +' }\n' +'}\n' +'\n' +'Invalid value for argument `0`: explicitly `undefined` values are not allowed.\n' +' at wn (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:1363)\n' +' at e.throwValidationError (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:10254)\n' +' at da (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:9013)\n' +' at pa (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:8487)\n' +' }\n' +'}\n' +'\n' +'Invalid value for argument `0`: explicitly `undefined` values are not allowed.\n' +' at wn (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:1363)\n' +' at e.throwValidationError (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:10254)\n' +' at da (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:9013)\n' +' at pa (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:8487)\n' +' at wn (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:1363)\n' +' at e.throwValidationError (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:10254)\n' +' at da (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:9013)\n' +' at pa (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:8487)\n' +' at da (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:9013)\n' +' at pa (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:8487)\n' +' at pa (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:8487)\n' +' at md (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:9660)\n' +' at pa (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:8076)\n' +' at da (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:8956)\n' +' at pa (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:8487)\n' +' at da (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:8956)\n' +' at mr (C:\\Users\\tomas\\workspace\\mindfuel\\try-prisma-fastify\\node_modules\\@prisma\\client\\runtime\\library.js:29:6038)'}
Environment (please complete the following information):
ZenStack version: 2.10.2, 2.11.3
Prisma version: 6.1.0
Database type: SQLite, PostgreSQL
Additional context
Issue seem to be linked with the usage of composite key in the update({ where call. If where is using PK then above code works fine.
The same as in the example for update+deleteMany happens with update+upsert.
The text was updated successfully, but these errors were encountered:
Description and expected behavior
Enhanced client errors on nested operations when
strictUndefinedCheck
is turned on.Given data model:
Running following code:
Fails with:
Environment (please complete the following information):
Additional context
update({ where
call. Ifwhere
is using PK then above code works fine.update+deleteMany
happens withupdate+upsert
.The text was updated successfully, but these errors were encountered: