[BUG] npm dedupe is broken when used in conjunction with workspaces for all versions >=7.20.3 #4168
Closed
2 tasks done
Labels
Bug
thing that needs fixing
Needs Triage
needs review for next steps
Release 8.x
work is associated with a specific npm 8 release
Is there an existing issue for this?
This issue exists in the latest npm version
Current Behavior
Inside an npm workspace, with packages
package-a
andpackage-z
, ifpackage-a
depends onpackage-z
, running npm dedupe will fail with the following error:npm dedupe attempts to look up the sibling package in the remote npm registry rather than within the workspace itself.
Expected Behavior
npm should first look among the packages in the workspace before looking for a package in the remote registry.
Steps To Reproduce
Here's the repro for the bug:
https://github.com/hzuo/test-dedupe-workspaces
Simply run
npm install
and thennpm dedupe
to repro.Environment
The text was updated successfully, but these errors were encountered: