pnpmDedupe post-update option causes all depencies to be needlessly downloaded and allows unintended script execution #41965
Unanswered
mestriga
asked this question in
Request Help
Replies: 2 comments 1 reply
-
|
The fact that the |
Beta Was this translation helpful? Give feedback.
1 reply
-
|
Hey, @jamietanna, I provided a repro showing .pnpmfile being executed in the free Mend hosted app, where ignoreScripts is set to false. Is there any other information you need? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
How are you running Renovate?
A Mend.io-hosted app
Which platform you running Renovate on?
GitHub.com
Which version of Renovate are you using?
43.66.4
Please tell us more about your question or problem
Renovate currently unconditionally passes just "--ignore-scripts" as an option to
pnpm dedupe.This causes all dependencies to be needlessly downloaded to the package store when just the lock file needs to be updated, and .pnpmfile.cjs to be execute without regards to the
allowScriptsglobal Renovate config.Since Renovate is frequently ran in resource limited environments, such as the free Mend Renovate app, downloading of full dependency payloads for the
dedupecommand should be suppressed with--lockfile-onlythe same way it is suppressed for theinstallcommand.--ignore-pnpmfileshould be passed to thededupecommand when applicable, the same way it is passed to theinstallcommand.pnpm dedupeunderstands the same command line options thatpnpm installunderstands, so that replacing "pnpm dedupe --ignore-scripts" with "pnpm dedupe ${args}" in lib/modules/manager/npm/post-update/pnpm.ts#L152 should make everything work as intended.Logs (if relevant)
Logs
Beta Was this translation helpful? Give feedback.
All reactions