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

16.14.2 ships with buggy npm #42397

Closed
haggholm opened this issue Mar 19, 2022 · 6 comments
Closed

16.14.2 ships with buggy npm #42397

haggholm opened this issue Mar 19, 2022 · 6 comments
Labels
npm Issues and PRs related to the npm client dependency or the npm registry.

Comments

@haggholm
Copy link

Version

v16.14.2

Platform

Linux glaurung 5.15.23-76051523-generic #202202110435164495230021.10~96763f1 SMP Tue Feb 15 19:52:40 U x86_64 x86_64 x86_64 GNU/Linux

Subsystem

No response

What steps will reproduce the bug?

In a Yarn monorepo,

yarn workspace some-workspace test

How often does it reproduce? Is there a required condition?

Every time

What is the expected behavior?

Tests should run

What do you see instead?

From a test script,

Error: Command failed: npm root -g
npm ERR! Workspaces not supported for global packages

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/petter/.npm/_logs/2022-03-19T01_58_39_948Z-debug-0.log

    at ChildProcess.exithandler (node:child_process:399:12)
    at ChildProcess.emit (node:events:526:28)
    at maybeClose (node:internal/child_process:1092:16)
    at Process.ChildProcess._handle.onexit (node:internal/child_process:302:5) {
  killed: false,
  code: 1,
  signal: null,
  cmd: 'npm root -g'
}

Additional information

This is a known bug in npm as of 8.5.0, fixed in npm/config#47

It’s resolved as of 8.5.5, but because Node 16.14.2 ships with the broken 8.5.0, it means it affects default nvm installs and anything that (like Github actions we rely on) can respect .nvmrc but offer no place to specify --latest-npm.

Releasing a Node 16 version with a newer npm should resolve the issue, I expect.

@richardlau richardlau added npm Issues and PRs related to the npm client dependency or the npm registry. v16.x labels Mar 19, 2022
@Trott
Copy link
Member

Trott commented Mar 19, 2022

Fixed in 76d85a8 which will make it's way to a 16.x release at some point.

@haggholm
Copy link
Author

Fixed in 76d85a8 which will make it's way to a 16.x release at some point.

👍 Good to hear. Is there any way to get a sense of when “some point” will happen? I realise it sounds self-serving (of course I think that the bug I reported needs a release, being Special); but it genuinely seems to me that pulling the latest image and running yarn may be a very common action in CI pipelines etc. for many people.

@Trott
Copy link
Member

Trott commented Mar 22, 2022

Is there any way to get a sense of when “some point” will happen?

It looks like it will go out in 17.8.0 some time in the next 48 hours (if all goes according to plan). #42425

From there, it's usually another 2 or 3 weeks before it shows up in an active LTS release, but it can be faster or slower than that depending on various factors. (If someone on the releasers team wants to chime in and provide somewhat more authoritative information, please do!)

@BethGriggs
Copy link
Member

The next release is scheduled for 2022-04-05 (nodejs/Release#658). Sometimes we do expedite or do additional interim releases to fix more critical bugs, but that's dependent on releaser's availability.

/cc @nodejs/npm

@Brandons404

This comment was marked as duplicate.

Keith-CY added a commit to nervosnetwork/neuron that referenced this issue Apr 7, 2022
Node.js 16.14.2, which is default in GitHub Action, introduces
a bug of npm, and should be fixed in 2022/04/05.

Ref: nodejs/node#42397
Keith-CY added a commit to nervosnetwork/neuron that referenced this issue Apr 7, 2022
Node.js 16.14.2, which is default in GitHub Action, introduces
a bug of npm, and should be fixed in 2022/04/05 but actually not.

Specify Node.js to 16.4.0 to avoid this exception.

Ref: nodejs/node#42397
domharrington added a commit to readmeio/metrics-sdks that referenced this issue Apr 15, 2022
node 16.14.2 ships with a buggy version of npm

Revert when this is resolved:
nodejs/node#42397
domharrington added a commit to readmeio/metrics-sdks that referenced this issue Apr 15, 2022
node 16.14.2 ships with a buggy version of npm

Revert when this is resolved:
nodejs/node#42397
domharrington added a commit to readmeio/metrics-sdks that referenced this issue Apr 15, 2022
node 16.14.2 ships with a buggy version of npm

Revert when this is resolved:
nodejs/node#42397
domharrington added a commit to readmeio/metrics-sdks that referenced this issue Apr 15, 2022
node 16.14.2 ships with a buggy version of npm

Revert when this is resolved:
nodejs/node#42397
domharrington added a commit to readmeio/metrics-sdks that referenced this issue Apr 15, 2022
…16.14.0) (#393)

* fix: python CI (upgrade black to 22.3.0)

Also added instructions for setting up a local python environment

psf/black#2964 (comment)

* fix: node.js ci 16.x (pin node.js version to 16.14.0)

node 16.14.2 ships with a buggy version of npm

Revert when this is resolved:
nodejs/node#42397
@XhmikosR
Copy link
Contributor

@Trott I think this can be closed now that v16.15.0 with npm 8.5.5 is out, right?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
npm Issues and PRs related to the npm client dependency or the npm registry.
Projects
None yet
Development

No branches or pull requests

6 participants