With the newest version of pnpm (7.2.1) I get an ...
# orm-help
o
With the newest version of pnpm (7.2.1) I get an error with the prisma client package name:
ERR_PNPM_BAD_PACKAGE_JSON  ****/pnpm-workspace-template/libs/prisma/node_modules/@prisma/client/package.json: Invalid name: “.prisma/client”
So pnpm doesn’t allow package names starting with a dot
.
Does a fix exist or is this a new issue?
r
Hi @Oliver St. - please try setting the
output
in the
generate client
in your
prisma.schema
file:
Copy code
generator client {
  provider = "prisma-client-js"
  output = "../node_modules/.prisma/client"
}
https://github.com/prisma/prisma/issues/13672#issuecomment-1152581890
o
Hi @Richard Ward I’ve set the output like this:
output        = "../node_modules/@prisma/client"
This is no problem, the folder structure is correct, but the generated package.json `name`value is
.prisma/client
-> pnpm references this as bad package name and fails
r
That's odd - I'm also using
7.2.1
and do not get that error
my
src/layers/prisma/node_modules/@prisma/client/package.json
has the following at the top:
Copy code
{
  "name": "@prisma/client",
  "version": "3.15.1",
How does yours look?
o
And how does your output-path look like?
r
Copy code
generator client {
  provider = "prisma-client-js"
  output = "../node_modules/.prisma/client"
}
in my
schema.prisma
file