pnpm: pnpm install recursive fails with `bin` in sub package that must be compiled first
pnpm version:
v3.2.0
Code to reproduce the issue:
See https://github.com/hgossler/pnpm-issue-1801 and follow the steps in the readme. This fails because pnpm attempts to chmod
the bin in sub-package1
before the prepare
script is run.
Expected behavior:
pnpm i -r
should work.
Actual behavior:
ERROR ENOENT: no such file or directory, chmod '... /pnpm-issue-2/packages/sub-package2/node_modules/sub-package1/dist/script.js'
It works if you run
cd packages/sub-package1
pnpm i
first.
Additional information:
node -v
prints:v11.10.1
- Windows, OS X, or Linux?: macOS
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 6
- Comments: 20 (4 by maintainers)
Commits related to this issue
- fix: link local bins created by postinstall scripts close #1801 — committed to pnpm/pnpm by zkochan a year ago
- fix: link local bins created by postinstall scripts close #1801 — committed to pnpm/pnpm by zkochan a year ago
- fix: link local bins created by postinstall scripts (#6728) close #1801 — committed to pnpm/pnpm by zkochan a year ago
- fix: link local bins created by postinstall scripts (#6728) close #1801 — committed to pnpm/pnpm by zkochan a year ago
- fix(ci): temporary workaround for pnpm bug https://github.com/pnpm/pnpm/issues/1801 — committed to Wave-Play/robo.js by Pkmmte 10 months ago
- fix: ci https://github.com/pnpm/pnpm/issues/1801 — committed to AbstractSDK/abstract.js by dalechyn 6 months ago
- fix: ci https://github.com/pnpm/pnpm/issues/1801 — committed to AbstractSDK/abstract.js by dalechyn 6 months ago
- Add validate bin entrypoint to fix https://github.com/pnpm/pnpm/issues/1801 — committed to TV-T/postgres-migrations by TV-T 6 months ago
In case it’s helpful, I did similar in my Github workflows.
also still present in
6.24.3
I just ran into this issue and submitted a PR for the underlying library (see above) which would fix it 🤞🏻
So, any project that uses Typescript and monorepo is not able to use PNPM without some kind of workaround. Hmm…