-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
yarn check: clarify "could be deduped" warning or yarn dedupe documentation #7568
Comments
I have the same issue, |
+1 I don't know what to do with yarn: 1.21.1 |
Having 1000 seemingly unresolvable warnings (at least the documentation and feedback given, makes it so) defeats the purpose of warnings. I don't like having warnings all over the place. You won't see when something new emerges. |
Seems like Perhaps this issue could be closed (would be nice to have deprecation warning when running the command in yarn v1 though) |
For me this solution https://stackoverflow.com/questions/41789887/dont-understand-yarn-check-warning is helpful |
AFAIK yarn 2 is not a replacement of yarn 1. Correct me if it has changed somehow recently. Its like a different tool. In case that goal did not change, deprecation does not make any sense and because other tool does not have this command does not mean the issue here is resolved. Either way, it's also still unclear how to dedupe, since even adding packages as root dependency in a version compatible across packages still end up in the specific versions duplicated as non-root dependency.
As I stated in my very first comment, removing lockfile does not fix it. So you simply had another issue. |
I'm also having this issue, any solution please? |
From documentation
yarn install
will always dedupe.However, when I run
yarn check
in my project, I get warnings, that "x" could be deduped from "y" to "z". In fact the different versions of same package(s) are indeed installed locally into the dependencies ownnode_modules
.For me the message sounds like it is possible to dedupe. And checking the version constraints it does make sense. When I run
yarn install
, with lockfile or without, it does not matter, the packages are still duplicated.Docs for dedupe or the message are either wrong, or phrased wrong?
Btw: This are not the root dependencies in my package.json. Adding every of the ~15 duped packages in my package.json sounds bad and also does not resolve the dupes, they are still installed, even I add the packages as root dependency in the compatible version.
yarn: 1.16.0
node: 10.1.0
The text was updated successfully, but these errors were encountered: