-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
npm 10.4.0 fails "npm install" when using node 18.19.1 and running under slow multi platform ARM build #7231
Comments
Found this issue that looks similar: nodejs/node#46188 |
A few more examples:
|
With a bit more log info:
|
We've recently started seeing this issue too after picking up an update from node Same symptoms, where this only seems to appear in the slow multi-platform ARM build from a linux/amd64 build machine. repo: https://github.com/mcneilco/acas Error:
|
We also seen the same issue: some logs:
Docker file used for the build: https://github.com/bpatrik/pigallery2/blob/e50861fce45899539f07dca32e44ecb30f46cf39/docker/debian-bullseye/Dockerfile.build using dockerx to build for arm64. This only happens on arm64 and only with debian. Works with alpine. Locking docker image to |
This issue may be a duplicate / other symptom of #7072 which has been fixed in npm |
* npm patch npm/cli#7231 (comment) * Delete huge unnecessary tools folder
And hopefully fixed in: nodejs/node#52505 |
Tested that with 10.5.2 that it fixed the issue. |
Upgrade the project to use nodejs-20 in the `Dockerfile`, and package.json engine block. More specific entries for `.dockerignore` will help keep the `COPY` step quick. Reasoning: - nodejs-18 is in LTS until May 2025, but nodejs-20 will be in LTS until May 2026. [^1] - node and npm are distributed together, and the `ubi9/nodejs-20` container has a newer version of npm included (10.7.0) than the current `ubi9/nodejs-18` container (10.5.0) - Given github issues [^2] and [^3], we can assume that the only versions of npm that will be stable in CI during the `npm install` phase are `npm@9` and `npm@>=10.5.2`. Any npm version <10.5.2 is at severe risk of encountering network errors when installing packages, especially when running in a qemu environment for non-native architecture builds. - Being very specific in the `package.json` `engines` block will help keep everyone on working versions of npm. [1]: https://nodejs.org/en/about/previous-releases [2]: npm/cli#7231 [3]: npm/cli#7072 Signed-off-by: Scott J Dickerson <[email protected]>
Upgrade the project to use nodejs-20 in the `Dockerfile`, and package.json engine block. More specific entries for `.dockerignore` will help keep the `COPY` step quick. Reasoning: - nodejs-18 is in LTS until May 2025, but nodejs-20 will be in LTS until May 2026. [^1] - node and npm are distributed together, and the `ubi9/nodejs-20` container has a newer version of npm included (10.7.0) than the current `ubi9/nodejs-18` container (10.5.0) - Given github issues [^2] and [^3], we can assume that the only versions of npm that will be stable in CI during the `npm install` phase are `npm@9` and `npm@>=10.5.2`. Any npm version <10.5.2 is at severe risk of encountering network errors when installing packages, especially when running in a qemu environment for non-native architecture builds. - Being very specific in the `package.json` `engines` block will help keep everyone on working versions of npm. [^1]: https://nodejs.org/en/about/previous-releases [^2]: npm/cli#7231 [^3]: npm/cli#7072 Signed-off-by: Scott J Dickerson <[email protected]>
Upgrade the project to use nodejs-20 in the `Dockerfile`, and package.json engine block. More specific entries for `.dockerignore` will help keep the `COPY` step quick. Reasoning: - nodejs-18 is in LTS until May 2025, but nodejs-20 will be in LTS until May 2026. [^1] - node and npm are distributed together, and the `ubi9/nodejs-20` container has a newer version of npm included (10.7.0) than the current `ubi9/nodejs-18` container (10.5.0) - Given github issues [^2] and [^3], we can assume that the only versions of npm that will be stable in CI during the `npm install` phase are `npm@9` and `npm@>=10.5.2`. Any npm version <10.5.2 is at severe risk of encountering network errors when installing packages, especially when running in a qemu environment for non-native architecture builds. - Being very specific in the `package.json` `engines` block will help keep everyone on working versions of npm. [^1]: https://nodejs.org/en/about/previous-releases [^2]: npm/cli#7231 [^3]: npm/cli#7072 Signed-off-by: Scott J Dickerson <[email protected]>
Upgrade the project to use nodejs-20 in the `Dockerfile`, and package.json engine block. More specific entries for `.dockerignore` will help keep the `COPY` step quick (especially for local dev image builds). Reasoning: - nodejs-18 is in LTS until May 2025, but nodejs-20 will be in LTS until May 2026. [^1] - node and npm are distributed together, and the `ubi9/nodejs-20` container has a newer version of npm included (10.7.0) than the current `ubi9/nodejs-18` container (10.5.0) - Given github issues [^2] and [^3], we can assume that the only versions of npm that will be stable in CI during the `npm install` phase are `npm@9` and `npm@>=10.5.2`. Any npm version <10.5.2 is at severe risk of encountering network errors when installing packages, especially when running in a qemu environment for non-native architecture builds. - Being very specific in the `package.json` `engines` block will help keep everyone on working versions of npm. [^1]: https://nodejs.org/en/about/previous-releases [^2]: npm/cli#7231 [^3]: npm/cli#7072 Signed-off-by: Scott J Dickerson <[email protected]>
Upgrade the project to use nodejs-20 in the `Dockerfile`, and package.json engine block. More specific entries for `.dockerignore` will help keep the `COPY` step quick (especially for local dev image builds). Reasoning: - nodejs-18 is in LTS until May 2025, but nodejs-20 will be in LTS until May 2026. [^1] - node and npm are distributed together, and the `ubi9/nodejs-20` container has a newer version of npm included (10.7.0) than the current `ubi9/nodejs-18` container (10.5.0) - Given github issues [^2] and [^3], we can assume that the only versions of npm that will be stable in CI during the `npm install` phase are `npm@9` and `npm@>=10.5.2`. Any npm version <10.5.2 is at severe risk of encountering network errors when installing packages, especially when running in a qemu environment for non-native architecture builds. - Being very specific in the `package.json` `engines` block will help keep everyone on working versions of npm. [^1]: https://nodejs.org/en/about/previous-releases [^2]: npm/cli#7231 [^3]: npm/cli#7072 Backport-of: konveyor#2062 Signed-off-by: Scott J Dickerson <[email protected]>
Upgrade the project to use nodejs-20 in the `Dockerfile`, and package.json engine block. More specific entries for `.dockerignore` will help keep the `COPY` step quick (especially for local dev image builds). Reasoning: - nodejs-18 is in LTS until May 2025, but nodejs-20 will be in LTS until May 2026. [^1] - node and npm are distributed together, and the `ubi9/nodejs-20` container has a newer version of npm included (10.7.0) than the current `ubi9/nodejs-18` container (10.5.0) - Given github issues [^2] and [^3], we can assume that the only versions of npm that will be stable in CI during the `npm install` phase are `npm@9` and `npm@>=10.5.2`. Any npm version <10.5.2 is at severe risk of encountering network errors when installing packages, especially when running in a qemu environment for non-native architecture builds. - Being very specific in the `package.json` `engines` block will help keep everyone on working versions of npm. [^1]: https://nodejs.org/en/about/previous-releases [^2]: npm/cli#7231 [^3]: npm/cli#7072 Backport-of: #2062 Signed-off-by: Scott J Dickerson <[email protected]>
Is there an existing issue for this?
This issue exists in the latest npm version
Current Behavior
We are building our node docker images from this repo:
https://github.com/connectedcars/docker-node
This has been working well until we upgraded to npm 10.4.0, npm 9.8.1 works without issue.
The build is a multi platform(linux/amd64 and linux/arm64) docker build on a linux/amd64 build machine. For the ARM build it consistently fails when using npm 10.4.0 with EPIPE error while fetching different npm packages. The arm64 build is about 10x slower than the amd64 build so this could indicate that we are hitting a race condition of some sort. We also tested on a Macbook Pro M3(linux/arm64) and here we don't see the issue.
Expected Behavior
Install packages without errors.
Steps To Reproduce
Environment
The text was updated successfully, but these errors were encountered: