[Prisma 7.0.0] TypeScript TS2742 errors with pnpm monorepo - cannot resolve @prisma/client-runtime-utils types
## Bug description After upgrading from Prisma 6.19.0 to Prisma 7.0.0 (released today, Nov 19, 2024), TypeScript compilation fails with `TS2742` errors in a pnpm monorepo setup with NestJS. The generated Prisma Client code cannot resolve types from `@prisma/client-runtime-utils` through pnpm's symlink structure. ## Reproduction steps ### Project Structure ``` library-system/ ├── apps/ │ └── api/ # NestJS app │ ├── prisma/ │ │ └── schema.prisma │ ├── generated/prisma/ # Custom output location │ └── package.json ├── package.json ├── pnpm-workspace.yaml └── .npmrc ``` ### Steps to reproduce 1. Set up a pnpm monorepo with NestJS 2. Configure Prisma with custom output: ```prisma generator client { provider = "prisma-client" output = "../generated/prisma" moduleFormat = "cjs" } ``` 3. Upgrade to Prisma 7.0.0: ```bash pnpm add @prisma/client@7.0.0 prisma@7.0.0 -D ``` 4. Run migrations and generate: ```bash pnpm exec prisma migrate dev pnpm exec prisma generate ``` 5. Try to start the NestJS dev server: ```bash pnpm run dev ``` ## Expected behavior The NestJS server should start without TypeScript compilation errors, as it did with Prisma 6.19.0. ## Actual behavior TypeScript compilation fails with multiple TS2742 errors: ``` apps/api dev: generated/prisma/internal/prismaNamespace.ts:114:14 - error TS2742: The inferred type of 'DbNull' cannot be named without a reference to '.pnpm/@pri
Posted by fsmm19 on Nov 19, 2025, 6:52 PM
Tags
Related issues
- Qt is fully of bugs on Wayland, some of which are unfixable because the API makes guarantees that are impossible to uphold.
- I took the plunge into GrapheneOS a week ago.
- [FEATURE] Multi-device Cowork: Allow concurrent Cowork agents on multiple machines under a single account
- [BUG] Claude Desktop spawns 1.8 GB Hyper-V VM on every launch, even for chat-only use
- Those cheap Bluetooth Tesla coils on AliExpress use A2DP audio as their control signal - a comparator converts the audio into spark pulses.
- I built a routine management app for my kids (7 and 10) called "Oh Yah!" after their constant "Oh yah!
Raise real-world problems, find people facing the same issue, and discuss solutions.2,000 issues0 comments
onboarding (SaaS)
Qt is fully of bugs on Wayland, some of which are unfixable because the API makes guarantees that are impossible to uphold.
I took the plunge into GrapheneOS a week ago.
[FEATURE] Multi-device Cowork: Allow concurrent Cowork agents on multiple machines under a single account
[BUG] Claude Desktop spawns 1.8 GB Hyper-V VM on every launch, even for chat-only use
Those cheap Bluetooth Tesla coils on AliExpress use A2DP audio as their control signal - a comparator converts the audio into spark pulses.
[Prisma 7.0.0] TypeScript TS2742 errors with pnpm monorepo - cannot resolve @prisma/client-runtime-utils types
I built a routine management app for my kids (7 and 10) called "Oh Yah!" after their constant "Oh yah!
> If it is open source, then I can build and install it myself.
[Prisma 7.0.0] TypeScript TS2742 errors with pnpm monorepo - cannot resolve @prisma/client-runtime-utils types
## Bug description After upgrading from Prisma 6.19.0 to Prisma 7.0.0 (released today, Nov 19, 2024), TypeScript compilation fails with `TS2742` errors in a pnpm monorepo setup with NestJS. The generated Prisma Client code cannot resolve types from `@prisma/client-runtime-utils` through pnpm's symlink structure. ## Reproduction steps ### Project Structure ``` library-system/ ├── apps/ │ └── api/ # NestJS app │ ├── prisma/ │ │ └── schema.prisma │ ├── generated/prisma/ # Custom output location │ └── package.json ├── package.json ├── pnpm-workspace.yaml └── .npmrc ``` ### Steps to reproduce 1. Set up a pnpm monorepo with NestJS 2. Configure Prisma with custom output: ```prisma generator client { provider = "prisma-client" output = "../generated/prisma" moduleFormat = "cjs" } ``` 3. Upgrade to Prisma 7.0.0: ```bash pnpm add @prisma/client@7.0.0 prisma@7.0.0 -D ``` 4. Run migrations and generate: ```bash pnpm exec prisma migrate dev pnpm exec prisma generate ``` 5. Try to start the NestJS dev server: ```bash pnpm run dev ``` ## Expected behavior The NestJS server should start without TypeScript compilation errors, as it did with Prisma 6.19.0. ## Actual behavior TypeScript compilation fails with multiple TS2742 errors: ``` apps/api dev: generated/prisma/internal/prismaNamespace.ts:114:14 - error TS2742: The inferred type of 'DbNull' cannot be named without a reference to '.pnpm/@pri
Comments (0)
No comments yet. Start the discussion.