Closed guilhermehn closed 1 year ago
This is the infamous npm 8 lockfile bug - please see https://github.com/npm/cli/issues/2606
The fix-has-install-script solved my problem, thanks for the help. Are you ok with keeping this issue open until the npm bug is fixed or should be closed as it's not caused by sharp itself?
Thanks for confirming this was the problem, I'll close. Sadly there's nothing we can do in sharp other that continue to point people at the npm bug report.
Possible install-time or require-time problem
npm install
is the same as the architecture and platform of Node.js used at runtime.Are you using the latest version of sharp?
sharp
as reported bynpm view sharp dist-tags.latest
.If you cannot confirm this, please upgrade to the latest version and try again before opening an issue.
If you are using another package which depends on a version of
sharp
that is not the latest, please open an issue against that package instead.Is this a problem with filesystem permissions?
If you are using npm v6 or earlier and installing as a
root
orsudo
user, have you tried with thenpm install --unsafe-perm
flag? Using npm 8.If you are using npm v7 or later, does the user running
npm install
own the directory it is run in? Yes.If you are using the
ignore-scripts
feature ofnpm
, have you tried with thenpm install --ignore-scripts=false
flag? Not using this flag.What is the complete output of running
npm install --verbose --foreground-scripts sharp
in an empty directory?With npm 6
``` npm info it worked if it ends with ok npm verb cli [ npm verb cli '/home/gnagatomo/.nvm/versions/node/v14.21.1/bin/node', npm verb cli '/home/gnagatomo/.nvm/versions/node/v14.21.1/bin/npm', npm verb cli 'install', npm verb cli '--verbose', npm verb cli '--foreground-scripts', npm verb cli 'sharp' npm verb cli ] npm info using npm@6.14.17 npm info using node@v14.21.1 npm verb npm-session 19eff35056d576e1 npm http fetch GET 304 https://redacted-private-registry.intranet/sharp 134ms (from cache) npm timing stage:loadCurrentTree Completed in 179ms npm timing stage:loadIdealTree:cloneCurrentTree Completed in 1ms npm timing stage:loadIdealTree:loadShrinkwrap Completed in 1ms npm http fetch GET 304 https://redacted-private-registry.intranet/color 87ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/detect-libc 154ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/simple-get 139ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/tunnel-agent 138ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/node-addon-api 161ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/prebuild-install 160ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/tar-fs 148ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/semver 159ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/color-convert 68ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/color-string 70ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/color-name 32ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/simple-swizzle 73ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/is-arrayish 32ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/github-from-package 106ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/mkdirp-classic 105ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/expand-template 109ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/minimist 108ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/napi-build-utils 108ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/rc 106ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/node-abi 112ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/pump 113ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/lru-cache 179ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/yallist 1010ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/once 52ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/end-of-stream 55ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/wrappy 42ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/deep-extend 63ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/ini 69ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/strip-json-comments 71ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/decompress-response 49ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/simple-concat 56ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/mimic-response 41ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/chownr 56ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/tar-stream 59ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/bl 42ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/fs-constants 47ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/readable-stream 49ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/inherits 148ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/buffer 57ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/ieee754 58ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/base64-js 62ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/util-deprecate 41ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/string_decoder 44ms (from cache) npm http fetch GET 304 https://redacted-private-registry.intranet/safe-buffer 32ms (from cache) npm timing stage:loadIdealTree:loadAllDepsIntoIdealTree Completed in 2556ms npm timing stage:loadIdealTree Completed in 2590ms npm timing stage:generateActionsToTake Completed in 19ms npm verb correctMkdir /home/gnagatomo/.npm/_locks correctMkdir not in flight; initializing npm verb lock using /home/gnagatomo/.npm/_locks/staging-e7fc3948f55a3584.lock for /home/gnagatomo/workspace/empty-repo/node_modules/.staging npm timing audit submit Completed in 92ms npm http fetch POST 200 https://redacted-private-registry.intranet/-/npm/v1/security/audits/quick 93ms npm timing audit body Completed in 11ms npm timing action:extract Completed in 367ms npm timing action:finalize Completed in 64ms npm timing action:refresh-package-json Completed in 129ms npm info lifecycle base64-js@1.5.1~preinstall: base64-js@1.5.1 npm info lifecycle chownr@1.1.4~preinstall: chownr@1.1.4 npm info lifecycle color-name@1.1.4~preinstall: color-name@1.1.4 npm info lifecycle color-convert@2.0.1~preinstall: color-convert@2.0.1 npm info lifecycle deep-extend@0.6.0~preinstall: deep-extend@0.6.0 npm info lifecycle detect-libc@2.0.1~preinstall: detect-libc@2.0.1 npm info lifecycle expand-template@2.0.3~preinstall: expand-template@2.0.3 npm info lifecycle fs-constants@1.0.0~preinstall: fs-constants@1.0.0 npm info lifecycle github-from-package@0.0.0~preinstall: github-from-package@0.0.0 npm info lifecycle ieee754@1.2.1~preinstall: ieee754@1.2.1 npm info lifecycle buffer@5.7.1~preinstall: buffer@5.7.1 npm info lifecycle inherits@2.0.4~preinstall: inherits@2.0.4 npm info lifecycle ini@1.3.8~preinstall: ini@1.3.8 npm info lifecycle is-arrayish@0.3.2~preinstall: is-arrayish@0.3.2 npm info lifecycle mimic-response@3.1.0~preinstall: mimic-response@3.1.0 npm info lifecycle decompress-response@6.0.0~preinstall: decompress-response@6.0.0 npm info lifecycle minimist@1.2.7~preinstall: minimist@1.2.7 npm info lifecycle mkdirp-classic@0.5.3~preinstall: mkdirp-classic@0.5.3 npm info lifecycle napi-build-utils@1.0.2~preinstall: napi-build-utils@1.0.2 npm info lifecycle safe-buffer@5.2.1~preinstall: safe-buffer@5.2.1 npm info lifecycle simple-concat@1.0.1~preinstall: simple-concat@1.0.1 npm info lifecycle simple-swizzle@0.2.2~preinstall: simple-swizzle@0.2.2 npm info lifecycle color-string@1.9.1~preinstall: color-string@1.9.1 npm info lifecycle string_decoder@1.3.0~preinstall: string_decoder@1.3.0 npm info lifecycle strip-json-comments@2.0.1~preinstall: strip-json-comments@2.0.1 npm info lifecycle rc@1.2.8~preinstall: rc@1.2.8 npm info lifecycle tunnel-agent@0.6.0~preinstall: tunnel-agent@0.6.0 npm info lifecycle util-deprecate@1.0.2~preinstall: util-deprecate@1.0.2 npm info lifecycle readable-stream@3.6.0~preinstall: readable-stream@3.6.0 npm info lifecycle bl@4.1.0~preinstall: bl@4.1.0 npm info lifecycle wrappy@1.0.2~preinstall: wrappy@1.0.2 npm info lifecycle once@1.4.0~preinstall: once@1.4.0 npm info lifecycle end-of-stream@1.4.4~preinstall: end-of-stream@1.4.4 npm info lifecycle tar-stream@2.2.0~preinstall: tar-stream@2.2.0 npm info lifecycle pump@3.0.0~preinstall: pump@3.0.0 npm info lifecycle tar-fs@2.1.1~preinstall: tar-fs@2.1.1 npm info lifecycle simple-get@4.0.1~preinstall: simple-get@4.0.1 npm info lifecycle yallist@4.0.0~preinstall: yallist@4.0.0 npm info lifecycle lru-cache@6.0.0~preinstall: lru-cache@6.0.0 npm info lifecycle semver@7.3.8~preinstall: semver@7.3.8 npm info lifecycle node-abi@3.31.0~preinstall: node-abi@3.31.0 npm info lifecycle color@4.2.3~preinstall: color@4.2.3 npm info lifecycle node-addon-api@5.1.0~preinstall: node-addon-api@5.1.0 npm info lifecycle prebuild-install@7.1.1~preinstall: prebuild-install@7.1.1 npm info lifecycle sharp@0.31.3~preinstall: sharp@0.31.3 npm timing action:preinstall Completed in 19ms npm info linkStuff base64-js@1.5.1 npm info linkStuff chownr@1.1.4 npm info linkStuff color-name@1.1.4 npm info linkStuff color-convert@2.0.1 npm info linkStuff deep-extend@0.6.0 npm info linkStuff detect-libc@2.0.1 npm info linkStuff expand-template@2.0.3 npm info linkStuff fs-constants@1.0.0 npm info linkStuff github-from-package@0.0.0 npm info linkStuff ieee754@1.2.1 npm info linkStuff buffer@5.7.1 npm info linkStuff inherits@2.0.4 npm info linkStuff ini@1.3.8 npm info linkStuff is-arrayish@0.3.2 npm info linkStuff mimic-response@3.1.0 npm info linkStuff decompress-response@6.0.0 npm info linkStuff minimist@1.2.7 npm info linkStuff mkdirp-classic@0.5.3 npm info linkStuff napi-build-utils@1.0.2 npm info linkStuff safe-buffer@5.2.1 npm info linkStuff simple-concat@1.0.1 npm info linkStuff simple-swizzle@0.2.2 npm info linkStuff color-string@1.9.1 npm info linkStuff string_decoder@1.3.0 npm info linkStuff strip-json-comments@2.0.1 npm info linkStuff rc@1.2.8 npm verb linkBins [ npm verb linkBins { rc: 'cli.js' }, npm verb linkBins '/home/gnagatomo/workspace/empty-repo/node_modules/.bin', npm verb linkBins false npm verb linkBins ] npm info linkStuff tunnel-agent@0.6.0 npm info linkStuff util-deprecate@1.0.2 npm info linkStuff readable-stream@3.6.0 npm info linkStuff bl@4.1.0 npm info linkStuff wrappy@1.0.2 npm info linkStuff once@1.4.0 npm info linkStuff end-of-stream@1.4.4 npm info linkStuff tar-stream@2.2.0 npm info linkStuff pump@3.0.0 npm info linkStuff tar-fs@2.1.1 npm info linkStuff simple-get@4.0.1 npm info linkStuff yallist@4.0.0 npm info linkStuff lru-cache@6.0.0 npm info linkStuff semver@7.3.8 npm verb linkBins [ npm verb linkBins { semver: 'bin/semver.js' }, npm verb linkBins '/home/gnagatomo/workspace/empty-repo/node_modules/.bin', npm verb linkBins false npm verb linkBins ] npm info linkStuff node-abi@3.31.0 npm info linkStuff color@4.2.3 npm info linkStuff node-addon-api@5.1.0 npm info linkStuff prebuild-install@7.1.1 npm verb linkBins [ npm verb linkBins { 'prebuild-install': 'bin.js' }, npm verb linkBins '/home/gnagatomo/workspace/empty-repo/node_modules/.bin', npm verb linkBins false npm verb linkBins ] npm info linkStuff sharp@0.31.3 npm timing action:build Completed in 28ms npm info lifecycle base64-js@1.5.1~install: base64-js@1.5.1 npm info lifecycle chownr@1.1.4~install: chownr@1.1.4 npm info lifecycle color-name@1.1.4~install: color-name@1.1.4 npm info lifecycle color-convert@2.0.1~install: color-convert@2.0.1 npm info lifecycle deep-extend@0.6.0~install: deep-extend@0.6.0 npm info lifecycle detect-libc@2.0.1~install: detect-libc@2.0.1 npm info lifecycle expand-template@2.0.3~install: expand-template@2.0.3 npm info lifecycle fs-constants@1.0.0~install: fs-constants@1.0.0 npm info lifecycle github-from-package@0.0.0~install: github-from-package@0.0.0 npm info lifecycle ieee754@1.2.1~install: ieee754@1.2.1 npm info lifecycle buffer@5.7.1~install: buffer@5.7.1 npm info lifecycle inherits@2.0.4~install: inherits@2.0.4 npm info lifecycle ini@1.3.8~install: ini@1.3.8 npm info lifecycle is-arrayish@0.3.2~install: is-arrayish@0.3.2 npm info lifecycle mimic-response@3.1.0~install: mimic-response@3.1.0 npm info lifecycle decompress-response@6.0.0~install: decompress-response@6.0.0 npm info lifecycle minimist@1.2.7~install: minimist@1.2.7 npm info lifecycle mkdirp-classic@0.5.3~install: mkdirp-classic@0.5.3 npm info lifecycle napi-build-utils@1.0.2~install: napi-build-utils@1.0.2 npm info lifecycle safe-buffer@5.2.1~install: safe-buffer@5.2.1 npm info lifecycle simple-concat@1.0.1~install: simple-concat@1.0.1 npm info lifecycle simple-swizzle@0.2.2~install: simple-swizzle@0.2.2 npm info lifecycle color-string@1.9.1~install: color-string@1.9.1 npm info lifecycle string_decoder@1.3.0~install: string_decoder@1.3.0 npm info lifecycle strip-json-comments@2.0.1~install: strip-json-comments@2.0.1 npm info lifecycle rc@1.2.8~install: rc@1.2.8 npm info lifecycle tunnel-agent@0.6.0~install: tunnel-agent@0.6.0 npm info lifecycle util-deprecate@1.0.2~install: util-deprecate@1.0.2 npm info lifecycle readable-stream@3.6.0~install: readable-stream@3.6.0 npm info lifecycle bl@4.1.0~install: bl@4.1.0 npm info lifecycle wrappy@1.0.2~install: wrappy@1.0.2 npm info lifecycle once@1.4.0~install: once@1.4.0 npm info lifecycle end-of-stream@1.4.4~install: end-of-stream@1.4.4 npm info lifecycle tar-stream@2.2.0~install: tar-stream@2.2.0 npm info lifecycle pump@3.0.0~install: pump@3.0.0 npm info lifecycle tar-fs@2.1.1~install: tar-fs@2.1.1 npm info lifecycle simple-get@4.0.1~install: simple-get@4.0.1 npm info lifecycle yallist@4.0.0~install: yallist@4.0.0 npm info lifecycle lru-cache@6.0.0~install: lru-cache@6.0.0 npm info lifecycle semver@7.3.8~install: semver@7.3.8 npm info lifecycle node-abi@3.31.0~install: node-abi@3.31.0 npm info lifecycle color@4.2.3~install: color@4.2.3 npm info lifecycle node-addon-api@5.1.0~install: node-addon-api@5.1.0 npm info lifecycle prebuild-install@7.1.1~install: prebuild-install@7.1.1 npm info lifecycle sharp@0.31.3~install: sharp@0.31.3 > sharp@0.31.3 install /home/gnagatomo/workspace/empty-repo/node_modules/sharp > (node install/libvips && node install/dll-copy && prebuild-install) || (node install/can-compile && node-gyp rebuild && node install/dll-copy) sharp: Downloading https://github.com/lovell/sharp-libvips/releases/download/v8.13.3/libvips-8.13.3-linux-x64.tar.br sharp: Integrity check passed for linux-x64 prebuild-install info begin Prebuild-install version 7.1.1 prebuild-install info looking for local prebuild @ prebuilds/sharp-v0.31.3-napi-v7-linux-x64.tar.gz prebuild-install info looking for cached prebuild @ /home/gnagatomo/.npm/_prebuilds/3edfda-sharp-v0.31.3-napi-v7-linux-x64.tar.gz prebuild-install info found cached prebuild prebuild-install info unpacking @ /home/gnagatomo/.npm/_prebuilds/3edfda-sharp-v0.31.3-napi-v7-linux-x64.tar.gz prebuild-install info unpack resolved to /home/gnagatomo/workspace/empty-repo/node_modules/sharp/build/Release/sharp-linux-x64.node prebuild-install info install Successfully installed prebuilt binary! npm verb lifecycle sharp@0.31.3~install: unsafe-perm in lifecycle true npm verb lifecycle sharp@0.31.3~install: PATH: /home/gnagatomo/.nvm/versions/node/v14.21.1/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/home/gnagatomo/workspace/empty-repo/node_modules/sharp/node_modules/.bin:/home/gnagatomo/workspace/empty-repo/node_modules/.bin:/home/gnagatomo/.nvm/versions/node/v14.21.1/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/home/gnagatomo/.local/bin:/usr/local/go/bin:/home/gnagatomo/.cargo/bin:/home/gnagatomo/workspace/gocode/bin:/usr/local/go/bin:/home/gnagatomo/workspace/external/fzf/bin npm verb lifecycle sharp@0.31.3~install: CWD: /home/gnagatomo/workspace/empty-repo/node_modules/sharp npm timing action:install Completed in 4323ms npm info lifecycle base64-js@1.5.1~postinstall: base64-js@1.5.1 npm info lifecycle chownr@1.1.4~postinstall: chownr@1.1.4 npm info lifecycle color-name@1.1.4~postinstall: color-name@1.1.4 npm info lifecycle color-convert@2.0.1~postinstall: color-convert@2.0.1 npm info lifecycle deep-extend@0.6.0~postinstall: deep-extend@0.6.0 npm info lifecycle detect-libc@2.0.1~postinstall: detect-libc@2.0.1 npm info lifecycle expand-template@2.0.3~postinstall: expand-template@2.0.3 npm info lifecycle fs-constants@1.0.0~postinstall: fs-constants@1.0.0 npm info lifecycle github-from-package@0.0.0~postinstall: github-from-package@0.0.0 npm info lifecycle ieee754@1.2.1~postinstall: ieee754@1.2.1 npm info lifecycle buffer@5.7.1~postinstall: buffer@5.7.1 npm info lifecycle inherits@2.0.4~postinstall: inherits@2.0.4 npm info lifecycle ini@1.3.8~postinstall: ini@1.3.8 npm info lifecycle is-arrayish@0.3.2~postinstall: is-arrayish@0.3.2 npm info lifecycle mimic-response@3.1.0~postinstall: mimic-response@3.1.0 npm info lifecycle decompress-response@6.0.0~postinstall: decompress-response@6.0.0 npm info lifecycle minimist@1.2.7~postinstall: minimist@1.2.7 npm info lifecycle mkdirp-classic@0.5.3~postinstall: mkdirp-classic@0.5.3 npm info lifecycle napi-build-utils@1.0.2~postinstall: napi-build-utils@1.0.2 npm info lifecycle safe-buffer@5.2.1~postinstall: safe-buffer@5.2.1 npm info lifecycle simple-concat@1.0.1~postinstall: simple-concat@1.0.1 npm info lifecycle simple-swizzle@0.2.2~postinstall: simple-swizzle@0.2.2 npm info lifecycle color-string@1.9.1~postinstall: color-string@1.9.1 npm info lifecycle string_decoder@1.3.0~postinstall: string_decoder@1.3.0 npm info lifecycle strip-json-comments@2.0.1~postinstall: strip-json-comments@2.0.1 npm info lifecycle rc@1.2.8~postinstall: rc@1.2.8 npm info lifecycle tunnel-agent@0.6.0~postinstall: tunnel-agent@0.6.0 npm info lifecycle util-deprecate@1.0.2~postinstall: util-deprecate@1.0.2 npm info lifecycle readable-stream@3.6.0~postinstall: readable-stream@3.6.0 npm info lifecycle bl@4.1.0~postinstall: bl@4.1.0 npm info lifecycle wrappy@1.0.2~postinstall: wrappy@1.0.2 npm info lifecycle once@1.4.0~postinstall: once@1.4.0 npm info lifecycle end-of-stream@1.4.4~postinstall: end-of-stream@1.4.4 npm info lifecycle tar-stream@2.2.0~postinstall: tar-stream@2.2.0 npm info lifecycle pump@3.0.0~postinstall: pump@3.0.0 npm info lifecycle tar-fs@2.1.1~postinstall: tar-fs@2.1.1 npm info lifecycle simple-get@4.0.1~postinstall: simple-get@4.0.1 npm info lifecycle yallist@4.0.0~postinstall: yallist@4.0.0 npm info lifecycle lru-cache@6.0.0~postinstall: lru-cache@6.0.0 npm info lifecycle semver@7.3.8~postinstall: semver@7.3.8 npm info lifecycle node-abi@3.31.0~postinstall: node-abi@3.31.0 npm info lifecycle color@4.2.3~postinstall: color@4.2.3 npm info lifecycle node-addon-api@5.1.0~postinstall: node-addon-api@5.1.0 npm info lifecycle prebuild-install@7.1.1~postinstall: prebuild-install@7.1.1 npm info lifecycle sharp@0.31.3~postinstall: sharp@0.31.3 npm timing action:postinstall Completed in 14ms npm verb unlock done using /home/gnagatomo/.npm/_locks/staging-e7fc3948f55a3584.lock for /home/gnagatomo/workspace/empty-repo/node_modules/.staging npm timing stage:executeActions Completed in 4977ms npm timing stage:rollbackFailedOptional Completed in 0ms npm timing stage:runTopLevelLifecycles Completed in 7803ms npm verb saving [ { name: 'sharp', spec: '^0.31.3', save: 'dependencies' } ] npm verb shrinkwrap skipping write for package.json because there were no changes. npm info lifecycle undefined~preshrinkwrap: undefined npm info lifecycle empty-repo@1.0.0~shrinkwrap: empty-repo@1.0.0 npm notice created a lockfile as package-lock.json. You should commit this file. npm info lifecycle empty-repo@1.0.0~postshrinkwrap: empty-repo@1.0.0 npm WARN empty-repo@1.0.0 No description npm WARN empty-repo@1.0.0 No repository field. + sharp@0.31.3 added 45 packages from 215 contributors and audited 45 packages in 7.896s found 0 vulnerabilities npm verb exit [ 0, true ] npm timing npm Completed in 8281ms npm info ok ```With npm 8
``` npm verb cli /home/gnagatomo/.nvm/versions/node/v16.19.0/bin/node /home/gnagatomo/.nvm/versions/node/v16.19.0/bin/npm npm info using npm@8.19.3 npm info using node@v16.19.0 npm timing npm:load:whichnode Completed in 0ms npm timing config:load:defaults Completed in 2ms npm timing config:load:file:/home/gnagatomo/.nvm/versions/node/v16.19.0/lib/node_modules/npm/npmrc Completed in 2ms npm timing config:load:builtin Completed in 2ms npm timing config:load:cli Completed in 4ms npm timing config:load:env Completed in 1ms npm timing config:load:file:/home/gnagatomo/workspace/empty-repo/.npmrc Completed in 0ms npm timing config:load:project Completed in 5ms npm timing config:load:file:/home/gnagatomo/.npmrc Completed in 2ms npm timing config:load:user Completed in 2ms npm timing config:load:file:/home/gnagatomo/.nvm/versions/node/v16.19.0/etc/npmrc Completed in 1ms npm timing config:load:global Completed in 1ms npm timing config:load:validate Completed in 1ms npm timing config:load:credentials Completed in 1ms npm timing config:load:setEnvs Completed in 1ms npm timing config:load Completed in 21ms npm timing npm:load:configload Completed in 22ms npm timing npm:load:mkdirpcache Completed in 1ms npm timing npm:load:mkdirplogs Completed in 0ms npm verb title npm install sharp npm verb argv "install" "--loglevel" "verbose" "--foreground-scripts" "sharp" npm timing npm:load:setTitle Completed in 2ms npm timing config:load:flatten Completed in 3ms npm timing npm:load:display Completed in 8ms npm verb logfile logs-max:10 dir:/home/gnagatomo/.npm/_logs npm verb logfile /home/gnagatomo/.npm/_logs/2023-01-23T23_00_44_903Z-debug-0.log npm timing npm:load:logFile Completed in 7ms npm timing npm:load:timers Completed in 0ms npm timing npm:load:configScope Completed in 0ms npm timing npm:load Completed in 40ms npm timing arborist:ctor Completed in 1ms npm timing arborist:ctor Completed in 0ms npm timing idealTree:init Completed in 17ms npm timing idealTree:userRequests Completed in 2ms npm http fetch GET 200 https://redacted-private-registry.intranet/sharp 129ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/color 73ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/tunnel-agent 94ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/detect-libc 101ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/semver 100ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/simple-get 107ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/tar-fs 108ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/node-addon-api 114ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/prebuild-install 115ms (cache revalidated) npm timing idealTree:#root Completed in 267ms npm http fetch GET 200 https://redacted-private-registry.intranet/color-string 138ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/napi-build-utils 136ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/expand-template 140ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/pump 137ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/color-convert 143ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/minimist 142ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/node-abi 140ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/decompress-response 139ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/chownr 142ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/simple-concat 145ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/tar-stream 143ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/github-from-package 165ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/mkdirp-classic 156ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/once 164ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/lru-cache 166ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/mkdirp-classic 177ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/safe-buffer 169ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/rc 178ms (cache revalidated) npm timing idealTree:node_modules/sharp Completed in 215ms npm http fetch GET 200 https://redacted-private-registry.intranet/color-name 41ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/color-name 48ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/simple-swizzle 46ms (cache revalidated) npm timing idealTree:node_modules/color Completed in 56ms npm timing idealTree:node_modules/color-convert Completed in 2ms npm timing idealTree:node_modules/color-name Completed in 0ms npm http fetch GET 200 https://redacted-private-registry.intranet/is-arrayish 35ms (cache revalidated) npm timing idealTree:node_modules/color-string Completed in 39ms npm timing idealTree:node_modules/detect-libc Completed in 0ms npm timing idealTree:node_modules/node-addon-api Completed in 0ms npm http fetch GET 200 https://redacted-private-registry.intranet/ini 55ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/end-of-stream 62ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/strip-json-comments 59ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/deep-extend 63ms (cache revalidated) npm timing idealTree:node_modules/prebuild-install Completed in 84ms npm timing idealTree:node_modules/expand-template Completed in 0ms npm timing idealTree:node_modules/github-from-package Completed in 0ms npm timing idealTree:node_modules/minimist Completed in 0ms npm timing idealTree:node_modules/mkdirp-classic Completed in 0ms npm timing idealTree:node_modules/napi-build-utils Completed in 0ms npm timing idealTree:node_modules/node-abi Completed in 0ms npm http fetch GET 200 https://redacted-private-registry.intranet/wrappy 62ms (cache revalidated) npm timing idealTree:node_modules/pump Completed in 67ms npm timing idealTree:node_modules/end-of-stream Completed in 0ms npm timing idealTree:node_modules/once Completed in 2ms npm timing idealTree:node_modules/rc Completed in 5ms npm timing idealTree:node_modules/deep-extend Completed in 0ms npm timing idealTree:node_modules/ini Completed in 0ms npm http fetch GET 200 https://redacted-private-registry.intranet/yallist 80ms (cache revalidated) npm timing idealTree:node_modules/semver Completed in 84ms npm timing idealTree:node_modules/lru-cache Completed in 3ms npm http fetch GET 200 https://redacted-private-registry.intranet/mimic-response 46ms (cache revalidated) npm timing idealTree:node_modules/simple-get Completed in 54ms npm timing idealTree:node_modules/decompress-response Completed in 3ms npm timing idealTree:node_modules/mimic-response Completed in 0ms npm timing idealTree:node_modules/simple-concat Completed in 0ms npm timing idealTree:node_modules/simple-swizzle Completed in 2ms npm timing idealTree:node_modules/is-arrayish Completed in 0ms npm timing idealTree:node_modules/strip-json-comments Completed in 0ms npm http fetch GET 200 https://redacted-private-registry.intranet/inherits 79ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/fs-constants 84ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/bl 92ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/readable-stream 100ms (cache revalidated) npm timing idealTree:node_modules/tar-fs Completed in 122ms npm timing idealTree:node_modules/chownr Completed in 0ms npm http fetch GET 200 https://redacted-private-registry.intranet/util-deprecate 55ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/string_decoder 63ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/buffer 74ms (cache revalidated) npm timing idealTree:node_modules/tar-stream Completed in 94ms npm http fetch GET 200 https://redacted-private-registry.intranet/base64-js 68ms (cache revalidated) npm http fetch GET 200 https://redacted-private-registry.intranet/ieee754 66ms (cache revalidated) npm timing idealTree:node_modules/bl Completed in 71ms npm timing idealTree:node_modules/buffer Completed in 3ms npm timing idealTree:node_modules/base64-js Completed in 0ms npm timing idealTree:node_modules/fs-constants Completed in 0ms npm timing idealTree:node_modules/ieee754 Completed in 0ms npm timing idealTree:node_modules/inherits Completed in 0ms npm timing idealTree:node_modules/readable-stream Completed in 4ms npm timing idealTree:node_modules/string_decoder Completed in 1ms npm timing idealTree:node_modules/safe-buffer Completed in 0ms npm timing idealTree:node_modules/tunnel-agent Completed in 0ms npm timing idealTree:node_modules/util-deprecate Completed in 0ms npm timing idealTree:node_modules/wrappy Completed in 0ms npm timing idealTree:node_modules/yallist Completed in 0ms npm timing idealTree:buildDeps Completed in 1195ms npm timing idealTree:fixDepFlags Completed in 2ms npm timing idealTree Completed in 1218ms npm timing reify:loadTrees Completed in 1220ms npm timing reify:diffTrees Completed in 4ms npm timing reify:retireShallow Completed in 2ms npm timing reify:createSparse Completed in 12ms npm timing reify:loadBundles Completed in 0ms npm http fetch POST 404 https://redacted-private-registry.intranet/-/npm/v1/security/advisories/bulk 45ms npm http fetch POST 200 https://redacted-private-registry.intranet/-/npm/v1/security/audits/quick 92ms npm timing auditReport:getReport Completed in 162ms npm timing auditReport:init Completed in 0ms npm timing reify:audit Completed in 162ms npm timing reifyNode:node_modules/chownr Completed in 181ms npm timing reifyNode:node_modules/strip-json-comments Completed in 181ms npm timing reifyNode:node_modules/ini Completed in 181ms npm timing reifyNode:node_modules/wrappy Completed in 181ms npm timing reifyNode:node_modules/once Completed in 182ms npm timing reifyNode:node_modules/end-of-stream Completed in 182ms npm timing reifyNode:node_modules/mkdirp-classic Completed in 182ms npm timing reifyNode:node_modules/simple-swizzle Completed in 183ms npm timing reifyNode:node_modules/color-name Completed in 183ms npm timing reifyNode:node_modules/color-string Completed in 183ms npm timing reifyNode:node_modules/ieee754 Completed in 188ms npm timing reifyNode:node_modules/inherits Completed in 187ms npm timing reifyNode:node_modules/fs-constants Completed in 187ms npm timing reifyNode:node_modules/mimic-response Completed in 188ms npm timing reifyNode:node_modules/decompress-response Completed in 188ms npm timing reifyNode:node_modules/lru-cache Completed in 188ms npm timing reifyNode:node_modules/tunnel-agent Completed in 188ms npm timing reifyNode:node_modules/color Completed in 188ms npm timing reifyNode:node_modules/string_decoder Completed in 192ms npm timing reifyNode:node_modules/util-deprecate Completed in 192ms npm timing reifyNode:node_modules/base64-js Completed in 193ms npm timing reifyNode:node_modules/yallist Completed in 191ms npm timing reifyNode:node_modules/expand-template Completed in 191ms npm timing reifyNode:node_modules/simple-concat Completed in 195ms npm timing reifyNode:node_modules/deep-extend Completed in 194ms npm timing reifyNode:node_modules/pump Completed in 195ms npm timing reifyNode:node_modules/napi-build-utils Completed in 194ms npm timing reifyNode:node_modules/safe-buffer Completed in 199ms npm timing reifyNode:node_modules/is-arrayish Completed in 198ms npm timing reifyNode:node_modules/color-convert Completed in 198ms npm timing reifyNode:node_modules/detect-libc Completed in 198ms npm timing reifyNode:node_modules/tar-stream Completed in 203ms npm timing reifyNode:node_modules/simple-get Completed in 202ms npm timing reifyNode:node_modules/buffer Completed in 207ms npm timing reifyNode:node_modules/github-from-package Completed in 208ms npm timing reifyNode:node_modules/rc Completed in 210ms npm timing reifyNode:node_modules/bl Completed in 213ms npm timing reifyNode:node_modules/prebuild-install Completed in 210ms npm timing reifyNode:node_modules/node-abi Completed in 213ms npm timing reifyNode:node_modules/minimist Completed in 221ms npm timing reifyNode:node_modules/readable-stream Completed in 231ms npm timing reifyNode:node_modules/node-addon-api Completed in 230ms npm timing reifyNode:node_modules/tar-fs Completed in 232ms npm timing reifyNode:node_modules/semver Completed in 234ms npm timing reifyNode:node_modules/sharp Completed in 238ms npm timing reify:unpack Completed in 244ms npm timing reify:unretire Completed in 0ms npm timing build:queue Completed in 3ms npm timing build:link:node_modules/prebuild-install Completed in 3ms npm timing build:link:node_modules/rc Completed in 2ms npm timing build:link:node_modules/semver Completed in 3ms npm timing build:link Completed in 4ms npm info run sharp@0.31.3 install node_modules/sharp node-gyp rebuild > sharp@0.31.3 install > node-gyp rebuild gyp info it worked if it ends with ok gyp verb cli [ gyp verb cli '/home/gnagatomo/.nvm/versions/node/v16.19.0/bin/node', gyp verb cli '/home/gnagatomo/.nvm/versions/node/v16.19.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js', gyp verb cli 'rebuild' gyp verb cli ] gyp info using node-gyp@9.1.0 gyp info using node@16.19.0 | linux | x64 gyp verb command rebuild [] gyp verb command clean [] gyp verb clean removing "build" directory gyp verb command configure [] gyp verb find Python Python is not set from command line or npm configuration gyp verb find Python Python is not set from environment variable PYTHON gyp verb find Python checking if "python3" can be used gyp verb find Python - executing "python3" to get executable path gyp verb find Python - executable path is "/usr/bin/python3" gyp verb find Python - executing "/usr/bin/python3" to get version gyp verb find Python - version is "3.10.6" gyp info find Python using Python version 3.10.6 found at "/usr/bin/python3" gyp verb get node dir no --target version specified, falling back to host node version: 16.19.0 gyp verb command install [ '16.19.0' ] gyp verb install input version string "16.19.0" gyp verb install installing version: 16.19.0 gyp verb install --ensure was passed, so won't reinstall if already installed gyp verb install version is already installed, need to check "installVersion" gyp verb got "installVersion" 9 gyp verb needs "installVersion" 9 gyp verb install version is good gyp verb get node dir target node version installed: 16.19.0 gyp verb build dir attempting to create "build" dir: /home/gnagatomo/workspace/empty-repo/node_modules/sharp/build gyp verb build dir "build" dir needed to be created? Yes gyp verb python symlink creating symlink to "/usr/bin/python3" at "/home/gnagatomo/workspace/empty-repo/node_modules/sharp/build/node_gyp_bins/python3" gyp verb build/config.gypi creating config file gyp verb build/config.gypi writing out config file: /home/gnagatomo/workspace/empty-repo/node_modules/sharp/build/config.gypi gyp verb config.gypi checking for gypi file: /home/gnagatomo/workspace/empty-repo/node_modules/sharp/config.gypi gyp verb common.gypi checking for gypi file: /home/gnagatomo/workspace/empty-repo/node_modules/sharp/common.gypi gyp verb gyp gyp format was not specified; forcing "make" gyp info spawn /usr/bin/python3 gyp info spawn args [ gyp info spawn args '/home/gnagatomo/.nvm/versions/node/v16.19.0/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py', gyp info spawn args 'binding.gyp', gyp info spawn args '-f', gyp info spawn args 'make', gyp info spawn args '-I', gyp info spawn args '/home/gnagatomo/workspace/empty-repo/node_modules/sharp/build/config.gypi', gyp info spawn args '-I', gyp info spawn args '/home/gnagatomo/.nvm/versions/node/v16.19.0/lib/node_modules/npm/node_modules/node-gyp/addon.gypi', gyp info spawn args '-I', gyp info spawn args '/home/gnagatomo/.cache/node-gyp/16.19.0/include/node/common.gypi', gyp info spawn args '-Dlibrary=shared_library', gyp info spawn args '-Dvisibility=default', gyp info spawn args '-Dnode_root_dir=/home/gnagatomo/.cache/node-gyp/16.19.0', gyp info spawn args '-Dnode_gyp_dir=/home/gnagatomo/.nvm/versions/node/v16.19.0/lib/node_modules/npm/node_modules/node-gyp', gyp info spawn args '-Dnode_lib_file=/home/gnagatomo/.cache/node-gyp/16.19.0/<(target_arch)/node.lib', gyp info spawn args '-Dmodule_root_dir=/home/gnagatomo/workspace/empty-repo/node_modules/sharp', gyp info spawn args '-Dnode_engine=v8', gyp info spawn args '--depth=.', gyp info spawn args '--no-parallel', gyp info spawn args '--generator-output', gyp info spawn args 'build', gyp info spawn args '-Goutput_dir=.' gyp info spawn args ] gyp verb command build [] gyp verb build type Release gyp verb architecture x64 gyp verb node dev dir /home/gnagatomo/.cache/node-gyp/16.19.0 gyp verb `which` succeeded for `make` /usr/bin/make gyp verb bin symlinks adding symlinks (such as Python), at "/home/gnagatomo/workspace/empty-repo/node_modules/sharp/build/node_gyp_bins", to PATH gyp info spawn make gyp info spawn args [ 'V=1', 'BUILDTYPE=Release', '-C', 'build' ] make: Entering directory '/home/gnagatomo/workspace/empty-repo/node_modules/sharp/build' cc -o Release/obj.target/nothing/../node-addon-api/nothing.o ../../node-addon-api/nothing.c '-DNODE_GYP_MODULE_NAME=nothing' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' -I/home/gnagatomo/.cache/node-gyp/16.19.0/include/node -I/home/gnagatomo/.cache/node-gyp/16.19.0/src -I/home/gnagatomo/.cache/node-gyp/16.19.0/deps/openssl/config -I/home/gnagatomo/.cache/node-gyp/16.19.0/deps/openssl/openssl/include -I/home/gnagatomo/.cache/node-gyp/16.19.0/deps/uv/include -I/home/gnagatomo/.cache/node-gyp/16.19.0/deps/zlib -I/home/gnagatomo/.cache/node-gyp/16.19.0/deps/v8/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -MMD -MF ./Release/.deps/Release/obj.target/nothing/../node-addon-api/nothing.o.d.raw -c rm -f Release/obj.target/../node-addon-api/nothing.a && ar crs Release/obj.target/../node-addon-api/nothing.a Release/obj.target/nothing/../node-addon-api/nothing.o ln -f "Release/obj.target/../node-addon-api/nothing.a" "Release/nothing.a" 2>/dev/null || (rm -rf "Release/nothing.a" && cp -af "Release/obj.target/../node-addon-api/nothing.a" "Release/nothing.a") touch Release/obj.target/libvips-cpp.stamp g++ -o Release/obj.target/sharp-linux-x64/src/common.o ../src/common.cc '-DNODE_GYP_MODULE_NAME=sharp-linux-x64' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-D__STDC_FORMAT_MACROS' '-DOPENSSL_NO_PINSHARED' '-DOPENSSL_THREADS' '-DNAPI_VERSION=7' '-DBUILDING_NODE_EXTENSION' -I/home/gnagatomo/.cache/node-gyp/16.19.0/include/node -I/home/gnagatomo/.cache/node-gyp/16.19.0/src -I/home/gnagatomo/.cache/node-gyp/16.19.0/deps/openssl/config -I/home/gnagatomo/.cache/node-gyp/16.19.0/deps/openssl/openssl/include -I/home/gnagatomo/.cache/node-gyp/16.19.0/deps/uv/include -I/home/gnagatomo/.cache/node-gyp/16.19.0/deps/zlib -I/home/gnagatomo/.cache/node-gyp/16.19.0/deps/v8/include -I../../node-addon-api -I../vendor/8.13.3/linux-x64/include -I../vendor/8.13.3/linux-x64/include/glib-2.0 -I../vendor/8.13.3/linux-x64/lib/glib-2.0/include -fPIC -pthread -Wall -Wextra -Wno-unused-parameter -m64 -O3 -fno-omit-frame-pointer -fno-rtti -fno-exceptions -std=gnu++14 -std=c++0x -fexceptions -Wall -Os -Wno-cast-function-type -MMD -MF ./Release/.deps/Release/obj.target/sharp-linux-x64/src/common.o.d.raw -c ../src/common.cc:24:10: fatal error: vips/vips8: No such file or directory 24 | #includeWhat is the output of running
npx envinfo --binaries --system --npmPackages=sharp --npmGlobalPackages=sharp
?I tried reading the logs but couldn't find the reason why prebuild-install isn't downloading the prebuilt binary and skips straight to
node-gyp rebuild
. It works fine when using npm's public registry and when using npm 6 with my private registry.