-
-
Notifications
You must be signed in to change notification settings - Fork 937
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
pnpm doesn't deduplicate dependencies correctly #3517
Comments
It seems that I guess renovate uses the latter way to update dependencies and that's why I found this issue. |
Closing this issue since I failed to reproduce this with a minimal repo. I will try to give more information if I see this issue twice. |
Perhaps the discussion #4143 is talking about this issue? |
@wujunchuan You can check my little tool pnpm-deduplicate and see if it helps in your case. |
pnpm version: 6.7.4
Code to reproduce the issue:
When I updated the dependency
@types/react
from^17.0.9
to^17.0.10
in my project, I got both version of@types/react
innode_modules
andpnpm-lock.yaml
, which causes the following error when I build the project withtsc
:For example, I can find that
@types/reactcss@1.2.3
is still using@types/react@17.0.9
based on what I saw inpnpm-lock.yaml
:Check this PR to see the code: ocavue/rino#646
Detailed step to reproduce this bug:
Expected behavior:
No deduplicate dependencies and no build error.
Actual behavior:
I have both
@types/react@17.0.9
and@types/react@17.0.10
installed.Additional information:
node -v
prints: v16.3.0 / v14.15.1I can fix this issue by removing
node_modules
andpnpm-lock.yaml
and reinstalling dependencies, but it's not an ideal way obviously.The text was updated successfully, but these errors were encountered: