P
Prisma4w ago
gkline

TypeError: Invalid enum value: __esModule

TypeError: Invalid enum value: __esModule ❯ Object.get node_modules/@prisma/client/runtime/library.js:131:902 On a branch I'm working on, I've started to encounter this error in one specific test file. It seems to fire while importing the enums in the test file, the test hasn't even started yet. I can confirm the enums being used exist in our node_modules/.prisma/client/index.d.ts All of our other test files work fine. Has anyone ever seen this before or know generally what could be causing this?
No description
3 Replies
Prisma AI Help
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!
Nurul
Nurul3w ago
How are you importing the enums?
gkline
gklineOP3w ago
We use a monorepo, so our db package is exporting export * from "@prisma/client" in the exported module /src/client.ts In this case this was being imported as import { SomeEnum } from "@ourcompany/db/client"

Did you find this page helpful?