Skip to content

fix(arborist): ignore obsolete peer sets during upgrades - #10279

Open
ychampion wants to merge 1 commit into
npm:latestfrom
ychampion:fix/simultaneous-peer-upgrades
Open

ychampion wants to merge 1 commit into
npm:latestfrom
ychampion:fix/simultaneous-peer-upgrades

Conversation

@ychampion

Copy link
Copy Markdown
Contributor

Upgrading ESLint, @eslint/js and typescript-eslint together can fail against peer constraints from the outgoing plugin graph, even though the requested versions install together from scratch.

When an existing peer entry blocks placement, check whether its source still has a valid dependency path to a top node or a bundle.
Ignore obsolete entries after the existing replacement and clobber checks; retain constraints from shared consumers, roots/workspaces and bundles.
The existing placement machinery still handles removal and reevaluation.

Fixes #9324.

Validation:

  • Regression tests cover installed and lockfile-only upgrades, transitive wrappers and stale cycles.
  • Controls retain shared consumers, direct root dependencies, ordinary/root-owned bundles and incompatible target graphs.
  • The reported ESLint version transition passes, followed by npm ls --all, a repeated install, npm ci and another clean dependency check.
  • Full node . run test-all: all 17 suites pass, including Arborist at 100% coverage, lint and template checks.

Assisted by AI.

Signed-off-by: ychampion <68075205+ychampion@users.noreply.github.com>
@ychampion
ychampion requested a review from a team as a code owner November 11, 2026 15:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] ERESOLVE when npm install new package versions with peer dependencies

1 participant