Commit 61b0e74
committed
npm_and_yarn: add --no-save to pnpm deep-update fallback
pnpm update <dep> --depth Infinity --lockfile-only rewrites caret ranges
in package.json and the matching specifier: lines in pnpm-lock.yaml to
^<currently-resolved-version> for every direct dep whose resolved version
is newer than its declared range floor. Dependabot returns only the
lockfile from this flow, so the package.json mutations are discarded
while the lockfile keeps specifier: entries that no longer match the
manifest, and a downstream frozen-lockfile install rejects the PR.
Adding --no-save tells pnpm to leave package.json ranges alone while
still resolving and writing the lockfile graph for the target transitive
dependency. Verified locally to: still bump the target transitive in
the lockfile, produce zero specifier: rewrites, produce zero
package.json mutations.
Fixes #151041 parent 10db257 commit 61b0e74
2 files changed
Lines changed: 15 additions & 8 deletions
File tree
- npm_and_yarn
- lib/dependabot/npm_and_yarn
- spec/dependabot/npm_and_yarn/file_updater
Lines changed: 13 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
72 | 72 | | |
73 | 73 | | |
74 | 74 | | |
75 | | - | |
76 | | - | |
77 | | - | |
78 | | - | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
79 | 86 | | |
80 | 87 | | |
81 | | - | |
82 | | - | |
| 88 | + | |
| 89 | + | |
83 | 90 | | |
84 | 91 | | |
85 | 92 | | |
| |||
Lines changed: 2 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
772 | 772 | | |
773 | 773 | | |
774 | 774 | | |
775 | | - | |
776 | | - | |
| 775 | + | |
| 776 | + | |
777 | 777 | | |
778 | 778 | | |
779 | 779 | | |
| |||
0 commit comments