node-sass: Cannot download "https://github.com/sass/node-sass/releases/download/v4.13.0/win32-x64-79_binding.node"
Hi I’m trying to make the webpack.configure.js file work, and when I want to install sass-loader and node sass (according to the document I have to install both) using the npm install sass-loader node-sass --save-dev , it fails and throws error
- NPM version 6.10.2
- Node version 12.9.1:
- Node Process { node: ‘12.9.1’, v8: ‘7.6.303.29-node.15’, uv: ‘1.31.0’, zlib: ‘1.2.11’, brotli: ‘1.0.7’, ares: ‘1.15.0’, modules: ‘72’, nghttp2: ‘1.39.2’, napi: ‘4’, llhttp: ‘1.1.4’, http_parser: ‘2.8.0’, openssl: ‘1.1.1c’, cldr: ‘35.1’, icu: ‘64.2’, tz: ‘2019a’, unicode: ‘12.1’ }
- Node Platform win32
- Node architecture x64
- node-sass version -
- npm node-sass versions` – (empty)
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 35 (13 by maintainers)
I’m getting this same error in OS x after updating to Catalina…I will leave my solution:
npm uninstall node-sass npm install node-sass
After that everything is up again…
For anyone else struggling with this issue I received a similar error message when working on OSX after upgrading my version of npm. Try removing your project’s local
package-lockfile and rerunnpm installto see if it resolves the error.@FlyRocketDrones This is a problem with your network proxy not allowing connections to Github and Amazon S3. There is nothing we can do here, worst case you can download the file from https://github.com/sass/node-sass/releases/tag/v4.13.0 and set environment variable
SASS_BINARY_PATHto the full path of thie binding (please note it will not be copied though!)This started to give an error when I upgraded to Catalina in MAC
I solved with: run node-sass uninstall and then sudo npm install --unsafe-perm -g node-sass
For those that are using Windows, first you have to install the last version of phyton and then the “Windows build tools” with the following command (on an an elevated PowerShell or CMD.exe (run as Administrator)
npm install --global --production windows-build-tools
Then run “npm i” or “npm install node-sass” on your project.
This worked for me.
@LucasOta thanks for this https://github.com/sass/node-sass/issues/2773#issuecomment-566644144, it did fix the issue I encountered.
Ionic@5.4.13 Used powershell as administrator.
Personal Gist Reference
For those who is having this issue, I think this is a windows issue. I’ve been having trouble since middle of this year (around August or September 2019 I think) with HTTPS connections in the command line. This has affected NPM installs and other scripts that need to get or call HTTPS connections.
I think is actually a windows issue. This is one of reason I HATE using Windows as a development machine. https://answers.microsoft.com/en-us/windows/forum/all/help-getting-https-to-work-in-command-line-in/6d226e12-f76b-47f8-8dac-1060f3047a08
FYI: I don’t have a network proxy or any kind of proxy setup in my network or my computers.
@saper makes sense. So for anyone who’s having this issue, it is caused by v4.13 hosted at a location that doesn’t seem secure to our networks. So unless you find a way to get this version thru proxy, you’ll have to stay at v4.12.
Downloading binary from https://github.com/sass/node-sass/releases/download/v4.13.0/win32-x64-79_binding.node Cannot download “https://github.com/sass/node-sass/releases/download/v4.13.0/win32-x64-79_binding.node”:
connect ECONNREFUSED 127.0.0.1:443
Hint: If github.com is not accessible in your location try setting a proxy via HTTP_PROXY, e.g.
or configure npm proxy via
Building: C:\Program Files\nodejs\node.exe D:\Practice\webpack\Colt-youtube\my\node_modules\node-gyp\bin\node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library= gyp info it worked if it ends with ok gyp verb cli [ gyp verb cli ‘C:\Program Files\nodejs\node.exe’, gyp verb cli ‘D:\Practice\webpack\Colt-youtube\my\node_modules\node-gyp\bin\node-gyp.js’, gyp verb cli ‘rebuild’, gyp verb cli ‘–verbose’, gyp verb cli ‘–libsass_ext=’, gyp verb cli ‘–libsass_cflags=’, gyp verb cli ‘–libsass_ldflags=’, gyp verb cli ‘–libsass_library=’ gyp verb cli ] gyp info using node-gyp@3.8.0 gyp info using node@13.0.1 | win32 | x64 gyp verb command rebuild [] gyp verb command clean [] gyp verb clean removing “build” directory gyp verb command configure [] gyp verb check python checking for Python executable “C:\Users\Mustafa.windows-build-tools\python27\python.exe” in the PATH gyp verb
whichfailed Error: not found: C:\Users\Mustafa.windows-build-tools\python27\python.exe gyp verbwhichfailed at getNotFoundError (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:13:12) gyp verbwhichfailed at F (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:68:19) gyp verbwhichfailed at E (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:80:29) gyp verbwhichfailed at D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:89:16 gyp verbwhichfailed at D:\Practice\webpack\Colt-youtube\my\node_modules\isexe\index.js:42:5 gyp verbwhichfailed at D:\Practice\webpack\Colt-youtube\my\node_modules\isexe\windows.js:36:5 gyp verbwhichfailed at FSReqCallback.oncomplete (fs.js:158:21) gyp verbwhichfailed C:\Users\Mustafa.windows-build-tools\python27\python.exe Error: not found: C:\Users\Mustafa.windows-build-tools\python27\python.exe gyp verbwhichfailed at getNotFoundError (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:13:12) gyp verbwhichfailed at F (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:68:19) gyp verbwhichfailed at E (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:80:29) gyp verbwhichfailed at D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:89:16 gyp verbwhichfailed at D:\Practice\webpack\Colt-youtube\my\node_modules\isexe\index.js:42:5 gyp verbwhichfailed at D:\Practice\webpack\Colt-youtube\my\node_modules\isexe\windows.js:36:5 gyp verbwhichfailed at FSReqCallback.oncomplete (fs.js:158:21) { gyp verbwhichfailed stack: ‘Error: not found: C:\Users\Mustafa\.windows-build-tools\python27\python.exe\n’ + gyp verbwhichfailed ’ at getNotFoundError (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:13:12)\n’ + gyp verbwhichfailed ’ at F (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:68:19)\n’ + gyp verbwhichfailed ’ at E (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:80:29)\n’ + gyp verbwhichfailed ’ at D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:89:16\n’ + gyp verbwhichfailed ’ at D:\Practice\webpack\Colt-youtube\my\node_modules\isexe\index.js:42:5\n’ + gyp verbwhichfailed ’ at D:\Practice\webpack\Colt-youtube\my\node_modules\isexe\windows.js:36:5\n’ + gyp verbwhichfailed ’ at FSReqCallback.oncomplete (fs.js:158:21)', gyp verbwhichfailed code: ‘ENOENT’ gyp verbwhichfailed } gyp verb could not find “C:\Users\Mustafa.windows-build-tools\python27\python.exe”. checking python launcher gyp verb could not find “C:\Users\Mustafa.windows-build-tools\python27\python.exe”. guessing location gyp verb ensuring that file exists: C:\Python27\python.exe gyp ERR! configure error gyp ERR! stack Error: Can’t find Python executable “C:\Users\Mustafa.windows-build-tools\python27\python.exe”, you can set the PYTHON env variable. gyp ERR! stack at PythonFinder.failNoPython (D:\Practice\webpack\Colt-youtube\my\node_modules\node-gyp\lib\configure.js:484:19) gyp ERR! stack at PythonFinder.<anonymous> (D:\Practice\webpack\Colt-youtube\my\node_modules\node-gyp\lib\configure.js:509:16) gyp ERR! stack at callback (D:\Practice\webpack\Colt-youtube\my\node_modules\graceful-fs\polyfills.js:295:20) gyp ERR! stack at FSReqCallback.oncomplete (fs.js:158:21) gyp ERR! System Windows_NT 6.1.7601 gyp ERR! command “C:\Program Files\nodejs\node.exe” “D:\Practice\webpack\Colt-youtube\my\node_modules\node-gyp\bin\node-gyp.js” “rebuild” “–verbose” “–libsass_ext=” “–libsass_cflags=” “–libsass_ldflags=” “–libsass_library=” gyp ERR! cwd D:\Practice\webpack\Colt-youtube\my\node_modules\node-sass gyp ERR! node -v v13.0.1 gyp ERR! node-gyp -v v3.8.0 gyp ERR! not ok Build failed with error code: 1 npm WARN bootstrap@4.3.1 requires a peer of jquery@1.9.1 - 3 but none is installed. You must install peer dependencies yourself. npm WARN bootstrap@4.3.1 requires a peer of popper.js@^1.14.7 but none is installed. You must install peer dependencies yourself. npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules\fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {“os”:“darwin”,“arch”:“any”} (current: {“os”:“win32”,“arch”:“x64”})npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! node-sass@4.13.0 postinstall:
node scripts/build.jsnpm ERR! Exit status 1 npm ERR! npm ERR! Failed at the node-sass@4.13.0 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!