Hi,
I tried to use the latest npm to install a package and it fails with errors like
npm WARN tar zlib: invalid distance too far back
npm WARN tarball tarball data for color-convert@https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz (sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==) seems to be corrupted. Trying again.
Using a more recent zlib (1.2.11), the installation completes.
Transaction check error:
file /usr/lib/node_modules/npm/node_modules/node-gyp from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/once from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/abbrev from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/ansi-regex from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/ansicolors from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/ansistyles from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/aproba from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/archy from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/asap from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/chownr from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/strip-ansi from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/cmd-shim from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/columnify from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/debuglog from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/dezalgo from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/glob from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/graceful-fs from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/has-unicode from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/hosted-git-info from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/imurmurhash from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/inflight from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/inherits from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/ini from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/init-package-json from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/mkdirp from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/npmlog from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/nopt from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/normalize-package-data from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/npm-install-checks from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/npm-package-arg from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/npm-user-validate from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/opener from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/read from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/read-cmd-shim from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/read-package-json from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/readable-stream from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/readdir-scoped-modules from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/retry from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/rimraf from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/semver from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/tar from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/text-table from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/unique-filename from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/validate-npm-package-license from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/validate-npm-package-name from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/which from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/wrappy from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
file /usr/lib/node_modules/npm/node_modules/write-file-atomic from install of npm-1:8.1.2-1.16.13.2.2.el7.x86_64 conflicts with file from package npm-1:3.10.10-1.6.17.1.1.el7.x86_64
Error Summary
-------------
I know what's causing those file errors. I didn't account for the directory replacement when upgrading from such an old version of Node.js. I will fix that.
I'm not sure why it isn't building the ppc64le version. The ExclusiveArch macro expands to: i386 i486 i586 i686 pentium3 pentium4 athlon geode x86_64 armv3l armv4b armv4l armv4tl armv5tel armv5tejl armv6l armv7l armv7hl armv7hnl aarch64 ppc64le s390x so it SHOULD be building.
This come fron epel-rpm-macros, In the file /etc/rpm/macros.zzz-epel-override
Override %nodejs_arches.
EPEL is providing nodejs on 64-bit ARM now, so the existing Red Hat provided
macro needs to be extended to include aarch64.
Requested by pbrobinson and sgallagh on IRC, 2016-09-16.
%nodejs_arches %{ix86} x86_64 %{arm} aarch64
So it is a bit of a chicken and egg problem if you want to change it.
The macro is defined to the arches for which nodejs is built, and nodejs is built for the arches the macro defines.
If the new nodejs package would be working on ppc64le if it was built there, then the epel-rpm-macros must de changed to include %{power64}, then with this update in the build root rebuild nodejs.
In Fedora 35 the macro is defined in /lib/rpm/macros.d/macros.nodejs as
I just want to point out some minor warnings, like:
...
warning: file /usr/lib/node_modules/npm/node_modules/realize-package-specifier: remove failed: No such file or directory
warning: file /usr/lib/node_modules/npm/node_modules/read-package-tree: remove failed: No such file or directory
...
This update has been submitted for testing by sgallagh.
This update's test gating status has been changed to 'ignored'.
This improves the situation, so I give karma. But why is there no ppc64le build?
This update has been pushed to testing.
Hi, I tried to use the latest npm to install a package and it fails with errors like
Using a more recent zlib (1.2.11), the installation completes.
Steps to reproduce:
I've tried updating an existing machine with the following installed packages:
Above packages are required by
netdata
, see also: https://bugzilla.redhat.com/show_bug.cgi?id=2041453Update command:
But
npm
has conflicts:Still I can correctly install on a clean machine.
Bodhi is disabling automatic push to stable due to negative karma. The maintainer may push manually if they determine that the issue is not severe.
I know what's causing those file errors. I didn't account for the directory replacement when upgrading from such an old version of Node.js. I will fix that.
I'm not sure why it isn't building the ppc64le version. The ExclusiveArch macro expands to:
i386 i486 i586 i686 pentium3 pentium4 athlon geode x86_64 armv3l armv4b armv4l armv4tl armv5tel armv5tejl armv6l armv7l armv7hl armv7hnl aarch64 ppc64le s390x
so it SHOULD be building.The NPM issue appears to be a reappearance of https://bugzilla.redhat.com/show_bug.cgi?id=1678825
I'm going to go the same route that the RHEL SCL did and bundle the upstream-included zlib.
sgallagh edited this update.
New build(s):
Removed build(s):
Karma has been reset.
This update has been submitted for testing by sgallagh.
This update has been pushed to testing.
Thanks,
npm install
works nowRegarding ppc64le
In EPEL 7 the nodejs_arches macro expands to:
<mock-chroot> sh-4.2# rpm -E %nodejs_arches i386 i486 i586 i686 pentium3 pentium4 athlon geode x86_64 armv3l armv4b armv4l armv4tl armv5tel armv5tejl armv6l armv7l armv7hl armv7hnl aarch64
This come fron epel-rpm-macros, In the file /etc/rpm/macros.zzz-epel-override
Override %nodejs_arches.
EPEL is providing nodejs on 64-bit ARM now, so the existing Red Hat provided
macro needs to be extended to include aarch64.
Requested by pbrobinson and sgallagh on IRC, 2016-09-16.
%nodejs_arches %{ix86} x86_64 %{arm} aarch64
So it is a bit of a chicken and egg problem if you want to change it. The macro is defined to the arches for which nodejs is built, and nodejs is built for the arches the macro defines.
If the new nodejs package would be working on ppc64le if it was built there, then the epel-rpm-macros must de changed to include %{power64}, then with this update in the build root rebuild nodejs.
In Fedora 35 the macro is defined in /lib/rpm/macros.d/macros.nodejs as
%nodejs_arches %{ix86} x86_64 %{arm} aarch64 %{power64} s390x
This update can be pushed to stable now if the maintainer wishes
With latest RPMs the update is good.
I just want to point out some minor warnings, like:
This update has been submitted for stable by bodhi.
This update has been pushed to stable.