Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

liamcmitchell
Copy link
Contributor

Discovered while investigating #8535

npm install --omit output doesn't show any removed packages.

This PR moves the omit calc into the diff calc so omits are handled like other resolution logic.

Improvements:

  • we see removals in CLI output
  • _createSparseTree no longer creates dirs that will only be cleaned later
  • no duplicate filterSet calculation, omit is calculated right after filters

I removed the trashList check on reifying node. Code coverage complained that this branch wasn't hit in any tests so I assume it should always be empty.

I think this uncovered one bug with workspaces in the test workspaces > reify workspaces omit dev dependencies > workspaces only. From my understanding of the docs, only workspace a should be touched, root and workspace b should still have their packages. I updated the test.

@liamcmitchell liamcmitchell requested a review from a team as a code owner September 14, 2025 18:57
@wraithgar wraithgar self-assigned this Sep 15, 2025
@wraithgar
Copy link
Member

At a glance this looks like a good improvement. It's gonna probably have to wait behind #8576 and #8579 for a real review.

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.

2 participants