-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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] non-previosly seen peer-dependency errors popping up in 8.6.0 #4664
Comments
Same problem here. No problems on 8.5.5, errors regarding peer dependencies on 8.6.0. |
I'm seeing this problem too but it's when running |
To be clear about how big this bug is, everybody with a CI step that does |
Git bisect shows it to be caused by bd96ae4. Reproduction at johanholmerin/npm-4664 |
Yup we are seeing the same error in our CI with 8.6.0, reverting to 8.5.5 works for now though. |
hi @johanholmerin thanks so much for taking the time to bisect and sending a reproduction, super handy and we super appreciate it! ❤️ It looks like what most folks here are seeing here is a legitimate I apologize for the extra churn this fix seems to be inflicting in some users, we're taking the extra steps of specifically documenting that in the How to fix it:In your project folder, run: npm config set legacy-peer-deps=true --location=project Then |
So just to confirm it is not expected behavior to have installs done with |
I understand what you're saying here, but why is a |
@ruyadorno running |
correct.
the root cause of this is that the package tree as described in your we added a step that validates that your
can you open a new issue for us with reproduction steps? we can take a look and see if this is a problem npm is creating for you there. |
In our case this broke our production builds.
I'd say this defeats the purpose of lockfiles. The only viable way to generate lockfiles is by using a package manager, which we can expect to make valid choices or actions based on user input, such as the I genuinely applaud the effort towards making NPM (and thus the ecosystem) more reliable, predictable and stable, I just think this change was a bit abrupt. Just my two cents. |
This comment was marked as spam.
This comment was marked as spam.
In the issue title "previosly" is misspelled and should be "previously". |
Also seeing this albeit my output shows identical version numbers are supposedly mismatched. This still seems off. example:
|
If anyone else is having related issues, please open a new issue so we can triage as I think we've gotten to the bottom of this one. |
@lukekarrys #3666 is an issue since 7.x I think. This is new with not really sure how that could be related to #3666 as that ticket is way older? I just ran into a similar issue with Shopware 6.4.10.0 and their build-administration script but that might be an issue on their end but it was working with 8.5 as well. |
@lukekarrys This is a new bug as @AndreasA is saying above and IMHO it's a serious one. Simplest case to reproduce it:
As mentioned above: |
There was a similar issue with 8.4.0 as the behavior regarding Which I think is good to do and I actually had expected to be the case for quite some time. Hhowever, as it changed the behavior (potential failings CIs) it should not have happened in a minor version. Any changes that are potentially breaking which this one is and the one from 8.4.0 should only occur in a major release because then people expect things to potentially break. Also if I understand it correctly, this issue happens because peer dependencies are not updated, if a dependency is updated? If so, isn't this also an issue with NPM because it should already fail the update in such a scenario. And maybe add an option to update the dependency and its peer dependencies. Similar to composer with |
Sorry to rehash this issue still, but what's the actual suggested solution for this? Always use |
I think most can be resolved using the |
Also, we add a .npmrc file to prevent peer-dependency errors in newer npm version. See npm/cli#4664 and npm/cli#4666
Also, we add a .npmrc file to prevent peer-dependency errors in newer npm version. See npm/cli#4664 and npm/cli#4666
Also, we add a .npmrc file to prevent peer-dependency errors in newer npm version. See npm/cli#4664 and npm/cli#4666
I have created a pinned issue summarizing this discussion as well as #4998. |
Is there an existing issue for this?
This issue exists in the latest npm version
Current Behavior
After upgrading from 8.5.5 to 8.6.0 I'm starting to get peer dependency issues that are not present when running under 8.5.5.
I don't see anything apparent in https://github.com/npm/cli/blob/latest/CHANGELOG.md#v860-2022-03-31 to account for this change. While it's possible these errors were present before, but hidden; the lack of changelog entry to account for this speaks against that.
Expected Behavior
I expect 8.6.0 to not error out on these peer-dependency issues.
Steps To Reproduce
No response
Environment
The text was updated successfully, but these errors were encountered: