Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug?]: nmHoistingLimits: dependencies incorrectly hoists past some dependencies with @scope names #6662

Open
1 task
Knagis opened this issue Jan 22, 2025 · 0 comments
Labels
bug Something isn't working

Comments

@Knagis
Copy link

Knagis commented Jan 22, 2025

Self-service

  • I'd be willing to implement a fix

Describe the bug

With some scoped package names some dependencies are hoisted to root level even though nmHoistingLimits: dependencies should have prevented that. This only triggers for some combination of dependencies.

To reproduce

package.json

{
  "devDependencies": {
    "@testing-library/jest-dom": "5.16.4",
    "@types/jest": "29.5.14"
  },
  "packageManager": "[email protected]"
}

.yarnrc.yml

enableGlobalCache: false
enableHardenedMode: false
enableTelemetry: false
nmHoistingLimits: dependencies
nodeLinker: node-modules

review node_modules - it has way more than just the two declared dependencies

Environment

System:
    OS: Windows 11 10.0.26100
    CPU: (16) x64 Intel(R) Core(TM) i7-10870H CPU @ 2.20GHz
  Binaries:
    Node: 23.6.0 - ~\AppData\Local\Temp\xfs-83a27508\node.CMD
    Yarn: 4.6.0 - ~\AppData\Local\Temp\xfs-83a27508\yarn.CMD
    npm: 10.9.2 - ~\AppData\Local\nvs\default\npm.CMD

Additional context

No response

@Knagis Knagis added the bug Something isn't working label Jan 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant