-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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?]: yarn install fails during 'Post-resolution validation' after upgrade to 4.0 #5841
Comments
Hm - can you try running |
@arcanis I'm working on it and will update soon. Another sidenote, it worked to get the non minified version, however the install ends with an error
|
So the problem was that we have been using |
Hello I'm having the same problem. Basically, we have two monorepos and I'd like to link packages from one monorepo to another using After a quick investigation the error occurs here
I can try to reproduce the issue |
Having the same issue here we are not using the |
I just run into this as well. I patched Yarn to add some debug logging to see if I can trace down what's happening. In my code, I was programmatically using Yarn (as part of the monoweave project). In monoweave, we update the version ranges in the package.jsons and then call:
it ends up there was a bug in monoweave which caused one of the dependency ranges to be set to a value which produced peer dependency warnings. In emitPeerDependencyWarnings, we collect ranges and pass them to simplifyRanges which ultimates passes each range to validRange: one of the peer dependency ranges being passed in was a workspace protocol: In my case, once I fixed my invalid peer dependencies, the error went away. This does seem to imply some sort of bug or lack of error handling in the emitPeerDependencyWarnings function though. Full stack trace (semverUtils.js:188 points to validRange).
|
… minor Previously, monoweave would throw an error if coerceImplicitPeerDependency was set to minor and a workspace peer dependency was pre-v0.1. This is because the version 0.0.x would get coerced to 0.0.0 resulting in the SemVer range of ^0.0.0. This range does not match anything, resulting in invalid peer dependencies. Related to yarnpkg/berry#5841.
… minor Previously, monoweave would throw an error if coerceImplicitPeerDependency was set to minor and a workspace peer dependency was pre-v0.1. This is because the version 0.0.x would get coerced to 0.0.0 resulting in the SemVer range of ^0.0.0. This range does not match anything, resulting in invalid peer dependencies. Related to yarnpkg/berry#5841.
… minor Previously, monoweave would throw an error if coerceImplicitPeerDependency was set to minor and a workspace peer dependency was pre-v0.1. This is because the version 0.0.x would get coerced to 0.0.0 resulting in the SemVer range of ^0.0.0. This range does not match anything, resulting in invalid peer dependencies. Related to yarnpkg/berry#5841.
… minor (#38) Previously, monoweave would throw an error if coerceImplicitPeerDependency was set to minor and a workspace peer dependency was pre-v0.1. This is because the version 0.0.x would get coerced to 0.0.0 resulting in the SemVer range of ^0.0.0. This range does not match anything, resulting in invalid peer dependencies. Related to yarnpkg/berry#5841.
✘ graphql-import@npm:1.0.2 [5bd70] (via ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0) However, those packages themselves have more dependencies listing graphql as peer dependency: ✘ apollo-utilities@npm:1.3.4 [1a50b] (via ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0 || ^15.0.0) Put together, the final range we computed is ^14.0.2 || ^15.0.0 |
Self-service
Describe the bug
After upgrading to yarn 4 and running yarn install I get the following error:
To reproduce
This is a huge private monorepo. I'm aware that this might get closed due to no way to reproduce, but I am posting in case others have the same issue and could add more context.
Note: The doc link in this issue template to
https://yarnpkg.com/advanced/sherlock
is brokenEnvironment
System: OS: macOS 14.0 CPU: (10) arm64 Apple M1 Max Binaries: Node: 19.9.0 - /private/var/folders/1h/8llh51vx1s1g998jrmj8_qg80000gn/T/xfs-68ee2d4f/node Yarn: 4.0.0 - /private/var/folders/1h/8llh51vx1s1g998jrmj8_qg80000gn/T/xfs-68ee2d4f/yarn npm: 9.6.3 - ~/.local/share/nvm/v19.9.0/bin/npm
Additional context
No response
The text was updated successfully, but these errors were encountered: