Node-gyp: Error npm-gyp

Created on 25 Apr 2019  路  4Comments  路  Source: nodejs/node-gyp

  • Node Version:12.00
  • Platform: Windows 10
  • Compiler:msbuild 2019,2017
  • Module:gulp-sass

output from power shell:

[email protected] install C:\Users\agani\Desktop\Gulp\node_modules\node-sass
node scripts/install.js

Downloading binary from https://github.com/sass/node-sass/releases/download/v4.11.0/win32-x64-72_binding.node
Cannot download "https://github.com/sass/node-sass/releases/download/v4.11.0/win32-x64-72_binding.node":

HTTP error 404 Not Found

Hint: If github.com is not accessible in your location
try setting a proxy via HTTP_PROXY, e.g.

  export HTTP_PROXY=http://example.com:1234

or configure npm proxy via

  npm config set proxy http://example.com:8080

[email protected] postinstall C:\Users\agani\Desktop\Gulp\node_modules\node-sass
node scripts/build.js

Building: C:\Program Files\nodejs\node.exe C:\Users\agani\Desktop\Gulp\node_modules\node-gyp\bin\node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
gyp ERR! build error
gyp ERR! stack Error: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\MSBuild.exe failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\Users\agani\Desktop\Gulp\node_modules\node-gyp\lib\build.js:262:23)
gyp ERR! stack at ChildProcess.emit (events.js:196:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:256:12)
gyp ERR! System Windows_NT 10.0.17763
gyp ERR! command "C:\Program Files\nodejs\node.exe" "C:\Users\agani\Desktop\Gulp\node_modules\node-gyp\bin\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd C:\Users\agani\Desktop\Gulp\node_modules\node-sass
gyp ERR! node -v v12.0.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
Build failed with error code: 1
npm WARN [email protected] No repository field.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] postinstall: node scripts/build.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall 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! C:\Users\agani\AppData\Roaming\npm-cache_logs\2019-04-25T12_58_44_283Z-debug.log

3531 warn [email protected] No repository field.
3532 warn optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
3533 warn notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
3534 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Valid OS:    darwin
3534 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Valid Arch:  any
3534 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Actual OS:   win32
3534 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Actual Arch: x64
3535 verbose stack Error: [email protected] postinstall: `node scripts/build.js`
3535 verbose stack Exit status 1
3535 verbose stack     at EventEmitter.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\index.js:301:16)
3535 verbose stack     at EventEmitter.emit (events.js:196:13)
3535 verbose stack     at ChildProcess.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\npm-lifecycle\lib\spawn.js:55:14)
3535 verbose stack     at ChildProcess.emit (events.js:196:13)
3535 verbose stack     at maybeClose (internal/child_process.js:1000:16)
3535 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:267:5)
3536 verbose pkgid [email protected]
3537 verbose cwd C:\Users\agani\Desktop\Gulp
3538 verbose Windows_NT 10.0.17763
3539 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "i" "gulp-sass"
3540 verbose node v12.0.0
3541 verbose npm  v6.9.0
3542 error code ELIFECYCLE
3543 error errno 1
3544 error [email protected] postinstall: `node scripts/build.js`
3544 error Exit status 1
3545 error Failed at the [email protected] postinstall script.
3545 error This is probably not a problem with npm. There is likely additional logging output above.
3546 verbose exit [ 1, true ]

Most helpful comment

You鈥檒l need to wait for node-sass 4.12.0 which adds support for Node.js 12: https://github.com/sass/node-sass/issues/2632

All 4 comments

I, too, am experiencing this issue.

You鈥檒l need to wait for node-sass 4.12.0 which adds support for Node.js 12: https://github.com/sass/node-sass/issues/2632

I am experiencing the same issue. Is there a work around to work with Old Projects. My existing project had got this issue.

@srikantmatihali Lock your node version to 11 instead of latest or version 12. That worked for me!

Was this page helpful?
0 / 5 - 0 ratings