Git Product home page Git Product logo

Comments (2)

Jolg42 avatar Jolg42 commented on September 27, 2024 3

Current workaround: using a custom out path works.
Example

generator client {
  provider = "prisma-client-js"
  output   = "../src/generated/client"
}

See https://www.prisma.io/docs/orm/prisma-client/setup-and-configuration/generating-prisma-client#using-a-custom-output-path

from prisma.

Jolg42 avatar Jolg42 commented on September 27, 2024

See internal Slack thread

One important thing to note, is that our current test has NPM_CONFIG_PRODUCTION=false & NODE_MODULES_CACHE=false set on Heroku as env vars.

After investigating, it looks like the Pruning devDependencies step of the heroku/nodejs buildpack changed, and is not skipped anymore.

A deployment using heroku/nodejs buildpack version 244, where runtime is working:

heroku buildpacks:set https://github.com/heroku/heroku-buildpack-nodejs.git#v244 -a name-of-app
....
remote: -----> Pruning devDependencies
remote:        Skipping because NPM_CONFIG_PRODUCTION is 'false'
remote:        

remote: -----> Compressing...
remote:        Done: 120.1M

A deployment using heroku/nodejs buildpack version 245, where runtime is failing with the Prisma Client error mentioned earlier:

heroku buildpacks:set https://github.com/heroku/heroku-buildpack-nodejs.git#v245 -a name-of-app

remote: -----> Pruning devDependencies
remote:        
remote:        devDependencies:
remote:        - @types/node 16.18.97
remote:        - heroku 8.11.5
remote:        - prisma 5.14.0-dev.74
remote:        - ts-node 10.9.2

remote: -----> Compressing...
remote:        Done: 89.7M

The changelog https://github.com/heroku/heroku-buildpack-nodejs/blob/HEAD/CHANGELOG.md
Shows that v245 added support for pnpm -> heroku/heroku-buildpack-nodejs#1224

Looking at https://github.com/heroku/heroku-buildpack-nodejs/blob/a409b633d7925c3002ba4568bc833093cbd75237/lib/dependencies.sh#L338
It looks like the behavior is not the same for pnpm as for yarn and npm and so this behavior is expected at the moment as the env vars are not used in that newer code path.

from prisma.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.