npm -v): 6.13.4node -v): v12.14.1node -p process.versions):node -p process.platform):node -p process.arch):node -p "require('node-sass').info"):node-sass 4.12.0 (Wrapper) [JavaScript]
libsass 3.5.4 (Sass Compiler) [C/C++]
npm ls node-sass):[email protected] XXX/XXXXX
└── [email protected]
-- Description:
When upgrading to python3 and node10/12, we have had issues and had to force a node-gyp version for some of our packages including node-sass.
The resolution was to force node 10/12 to use node-gyp version 6.0.1. I am wondering if there are any consequences on a node-sass compatibilities of functionality if any of using this version of node-gyp rather than the recommended one?
Current Workaround steps:
Update package.json:
"resolutions": {
"node-sass/node-gyp": "^6.0.0"
},
npm explore npm -g -- npm install node-gyp@latest
yarn audit fix
yarn install
md5-9ba7f6ef8d465990767d4f2ff1edea58
node-pre-gyp info it worked if it ends with ok
node-pre-gyp info using [email protected]
node-pre-gyp info using [email protected] | darwin | x64
node-pre-gyp WARN Using request for node-pre-gyp https download
node-pre-gyp info check checked for \"/Users/userXXXX/develop/project/node_modules/canvas/build/Release/canvas.node\" (not found)
node-pre-gyp http GET https://github.com/node-gfx/node-canvas-prebuilt/releases/download/v2.5.0/canvas-v2.5.0-node-v72-darwin-unknown-x64.tar.gz
node-pre-gyp WARN Pre-built binaries not installable for [email protected] and [email protected] (node-v72 ABI, unknown) (falling back to source compile with node-gyp)
node-pre-gyp WARN Hit error self signed certificate in certificate chain
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | darwin | x64
gyp info ok
gyp info it worked if it ends with ok
gyp info using [email protected]
gyp info using [email protected] | darwin | x64
gyp ERR! configure error
gyp ERR! stack Error: Command failed: /usr/local/bin/python2 -c import sys; print \"%s.%s.%s\" % sys.version_info[:3];
gyp ERR! stack Your PYTHONPATH points to a site-packages dir for Python 3.x but you are running Python 2.x!
gyp ERR! stack PYTHONPATH is currently: \"/usr/local/lib/python3.7/site-packages\"
gyp ERR! stack You should `unset PYTHONPATH` to fix this.
gyp ERR! stack
gyp ERR! stack at ChildProcess.exithandler (child_process.js:295:12)
gyp ERR! stack at ChildProcess.emit (events.js:223:5)
gyp ERR! stack at maybeClose (internal/child_process.js:1021:16)
gyp ERR! stack at Socket.<anonymous> (internal/child_process.js:430:11)
gyp ERR! stack at Socket.emit (events.js:223:5)
gyp ERR! stack at Pipe.<anonymous> (net.js:664:12)
gyp ERR! System Darwin 18.7.0
gyp ERR! command \"/Users/userXXXX/.nvm/versions/node/v12.14.1/bin/node\" \"/Users/userXXXX/develop/project/node_modules/node-gyp/bin/node-gyp.js\" \"configure\" \"--fallback-to-build\" \"--module=/Users/userXXXX/develop/project/node_modules/canvas/build/Release/canvas.node\" \"--module_name=canvas\" \"--module_path=/Users/userXXXX/develop/project/node_modules/canvas/build/Release\" \"--napi_version=5\" \"--node_abi_napi=napi\" \"--napi_build_version=0\" \"--node_napi_label=node-v72\"
gyp ERR! cwd /Users/userXXXX/develop/project/node_modules/canvas
gyp ERR! node -v v12.14.1
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute '/Users/userXXXX/.nvm/versions/node/v12.14.1/bin/node /Users/userXXXX/develop/project/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/Users/userXXXX/develop/project/node_modules/canvas/build/Release/canvas.node --module_name=canvas --module_path=/Users/userXXXX/develop/project/node_modules/canvas/build/Release --napi_version=5 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v72' (1)
node-pre-gyp ERR! stack at ChildProcess.<anonymous> (/Users/userXXXX/develop/project/node_modules/canvas/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack at ChildProcess.emit (events.js:223:5)
node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:1021:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:283:5)
node-pre-gyp ERR! System Darwin 18.7.0
node-pre-gyp ERR! command \"/Users/userXXXX/.nvm/versions/node/v12.14.1/bin/node\" \"/Users/userXXXX/develop/project/node_modules/canvas/node_modules/.bin/node-pre-gyp\" \"install\" \"--fallback-to-build\"
node-pre-gyp ERR! cwd /Users/userXXXX/develop/project/node_modules/canvas
node-pre-gyp ERR! node -v v12.14.1
node-pre-gyp ERR! node-pre-gyp -v v0.11.0
node-pre-gyp ERR! not ok
Failed to execute '/Users/userXXXX/.nvm/versions/node/v12.14.1/bin/node /Users/userXXXX/develop/project/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/Users/userXXXX/develop/project/node_modules/canvas/build/Release/canvas.[-/19] ⠐ waitin
You are installing older version of node-sass that doesn't not support your version of Node. Consult the compatibility table at the very top of the README.