mapbox / mapbox/node-pre-gyp

npm install fails with node-pre-gyp error

Open
#486 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
1.2k
Forks
271
Avg merge
23h 40m
Merged PRs (30d)
2

Description

I recently upgraded my npm, and now it's impossible to compile code in my project. When I run npm install, I get the error output below. This is a Nuxt / Vue project and I have node v12.13.0 / npm v6.12.0. Any help would be so appreciated! I am stuck and can't develop until I resolve this.

`suaif:pietra-website noellesuaifan$ sudo npm install

> fsevents@1.2.7 install /Users/noellesuaifan/carbon-code/pietra-website/node_modules/fsevents
> node install

node-pre-gyp WARN Using request for node-pre-gyp https download
node-pre-gyp ERR! install error
node-pre-gyp ERR! stack Error: Unsupported target version: v4.4.2
node-pre-gyp ERR! stack at get_runtime_abi (/Users/noellesuaifan/carbon-code/pietra-website/node_modules/fsevents/node_modules/node-pre-gyp/lib/util/versioning.js:173:23)
node-pre-gyp ERR! stack at Object.module.exports.evaluate (/Users/noellesuaifan/carbon-code/pietra-website/node_modules/fsevents/node_modules/node-pre-gyp/lib/util/versioning.js:295:19)
node-pre-gyp ERR! stack at install (/Users/noellesuaifan/carbon-code/pietra-website/node_modules/fsevents/node_modules/node-pre-gyp/lib/install.js:204:31)
node-pre-gyp ERR! stack at Object.self.commands. [as install] (/Users/noellesuaifan/carbon-code/pietra-website/node_modules/fsevents/node_modules/node-pre-gyp/lib/node-pre-gyp.js:52:37)
node-pre-gyp ERR! stack at run (/Users/noellesuaifan/carbon-code/pietra-website/node_modules/fsevents/node_modules/node-pre-gyp/bin/node-pre-gyp:82:30)
node-pre-gyp ERR! stack at Object. (/Users/noellesuaifan/carbon-code/pietra-website/node_modules/fsevents/node_modules/node-pre-gyp/bin/node-pre-gyp:134:1)
node-pre-gyp ERR! stack at Module._compile (internal/modules/cjs/loader.js:956:30)
node-pre-gyp ERR! stack at Object.Module._extensions..js (internal/modules/cjs/loader.js:973:10)
node-pre-gyp ERR! stack at Module.load (internal/modules/cjs/loader.js:812:32)
node-pre-gyp ERR! stack at Function.Module._load (internal/modules/cjs/loader.js:724:14)
node-pre-gyp ERR! System Darwin 19.2.0
node-pre-gyp ERR! command "/usr/local/bin/node" "/Users/noellesuaifan/carbon-code/pietra-website/node_modules/fsevents/node_modules/node-pre-gyp/bin/node-pre-gyp" "install" "--fallback-to-build"
node-pre-gyp ERR! cwd /Users/noellesuaifan/carbon-code/pietra-website/node_modules/fsevents
node-pre-gyp ERR! node -v v12.13.0
node-pre-gyp ERR! node-pre-gyp -v v0.10.3
node-pre-gyp ERR! not ok
Unsupported target version: v4.4.2

> grpc@1.19.0 install /Users/noellesuaifan/carbon-code/pietra-website/node_modules/grpc
> node-pre-gyp install --fallback-to-build --library=static_library

node-pre-gyp WARN Using request for node-pre-gyp https download
node-pre-gyp ERR! install error
node-pre-gyp ERR! stack Error: Unsupported target version: v4.4.2
node-pre-gyp ERR! stack at get_runtime_abi (/Users/noellesuaifan/carbon-code/pietra-website/node_modules/grpc/node_modules/node-pre-gyp/lib/util/versioning.js:173:23)
node-pre-gyp ERR! stack at Object.module.exports.evaluate (/Users/noellesuaifan/carbon-code/pietra-website/node_modules/grpc/node_modules/node-pre-gyp/lib/util/versioning.js:295:19)
node-pre-gyp ERR! stack at install (/Users/noellesuaifan/carbon-code/pietra-website/node_modules/grpc/node_modules/node-pre-gyp/lib/install.js:216:31)
node-pre-gyp ERR! stack at Object.self.commands. [as install] (/Users/noellesuaifan/carbon-code/pietra-website/node_modules/grpc/node_modules/node-pre-gyp/lib/node-pre-gyp.js:52:37)
node-pre-gyp ERR! stack at run (/Users/noellesuaifan/carbon-code/pietra-website/node_modules/grpc/node_modules/node-pre-gyp/bin/node-pre-gyp:82:30)
node-pre-gyp ERR! stack at Object. (/Users/noellesuaifan/carbon-code/pietra-website/node_modules/grpc/node_modules/node-pre-gyp/bin/node-pre-gyp:134:1)
node-pre-gyp ERR! stack at Module._compile (internal/modules/cjs/loader.js:956:30)
node-pre-gyp ERR! stack at Object.Module._extensions..js (internal/modules/cjs/loader.js:973:10)
node-pre-gyp ERR! stack at Module.load (internal/modules/cjs/loader.js:812:32)
node-pre-gyp ERR! stack at Function.Module._load (internal/modules/cjs/loader.js:724:14)
node-pre-gyp ERR! System Darwin 19.2.0
node-pre-gyp ERR! command "/usr/local/bin/node" "/Users/noellesuaifan/carbon-code/pietra-website/node_modules/grpc/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build" "--library=static_library"
node-pre-gyp ERR! cwd /Users/noellesuaifan/carbon-code/pietra-website/node_modules/grpc
node-pre-gyp ERR! node -v v12.13.0
node-pre-gyp ERR! node-pre-gyp -v v0.12.0
node-pre-gyp ERR! not ok
Unsupported target version: v4.4.2
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.7 (node_modules/fsevents):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.7 install: `node install`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! grpc@1.19.0 install: `node-pre-gyp install --fallback-to-build --library=static_library`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the grpc@1.19.0 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR! /Users/noellesuaifan/.npm/_logs/2020-01-21T17_55_40_713Z-debug.log`

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing npm install with the reported Node.js and npm versions, focusing on the fsevents@1.2.7 and grpc@1.19.0 failures. Trace the node-pre-gyp versioning.js locations shown in the stack traces and compare the reported target version with the installed runtime. Done means the cause is identified and npm install completes or compatibility guidance is verified.

Written by the indexing model from the issue text.

Assessment

Tech stack
grpc, javascript, node.js
Domain
build-system, tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.