Colt / webpack-demo-app

Accompanies my 10-part Youtube Webpack course. Each commit comes with detailed notes.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Failed at the node-sass@4.13.0 postinstall script.

eXvimmer opened this issue · comments

Hi I'm trying to make the webpack.configure.js file work, and when I want to install sass-loader and node sass using the npm install sass-loader node-sass --save-dev , it fails and throws error,
Failed at the node-sass@4.13.0 postinstall script.
NPM version 6.10.2
Node version 12.9.1
I installed the version 13 of node and the newer version of npm and it is still the same. can you help me please?
this is the log file
https://gist.github.com/Mustafa-Hayati/0fbb5bbbc95aa2add18a4a8f5513eabf

can you please put the the full output from the console

I can't replicate

$ node -v
v10.16.3

ehurst@IT8964L MINGW64 /c/Users/ehurst/Github/webpack-demo-app (master)
$ npm -v
6.11.3```

```ehurst@IT8964L MINGW64 /c/Users/ehurst/Github/webpack-demo-app (master)
$ npm install sass-loader node-sass --save-dev

> node-sass@4.13.0 install C:\Users\ehurst\Github\webpack-demo-app\node_modules\node-sass
> node scripts/install.js

Downloading binary from https://github.com/sass/node-sass/releases/download/v4.13.0/win32-x64-64_binding.node
Download complete..] - :
Binary saved to C:\Users\ehurst\Github\webpack-demo-app\node_modules\node-sass\vendor\win32-x64-64\binding.node
Caching binary to C:\Users\ehurst\AppData\Roaming\npm-cache\node-sass\4.13.0\win32-x64-64_binding.node

> node-sass@4.13.0 postinstall C:\Users\ehurst\Github\webpack-demo-app\node_modules\node-sass
> node scripts/build.js

Binary found at C:\Users\ehurst\Github\webpack-demo-app\node_modules\node-sass\vendor\win32-x64-64\binding.node
Testing binary
Binary is fine
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.7 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.7: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})

+ sass-loader@7.3.1
+ node-sass@4.13.0
added 846 packages from 457 contributors and audited 10145 packages in 47.661s
found 123 vulnerabilities (3 moderate, 120 high)
  run `npm audit fix` to fix them, or `npm audit` for details```

sorry - just saw your gist. Its asking you to upgrade your version of node

2 warn npm You should probably upgrade to a newer version of node as we
3 warn npm can't make any promises that npm will work with this version.
4 warn npm Supported releases of Node.js are the latest release of 6, 8, 9, 10, 11, 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.

export HTTP_PROXY=http://example.com:1234
or configure npm proxy via

npm config set proxy http://example.com:8080
node-sass@4.13.0 postinstall D:\Practice\webpack\Colt-youtube\my\node_modules\node-sass
node scripts/build.js

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 which failed Error: not found: C:\Users\Mustafa.windows-build-tools\python27\python.exe
gyp verb which failed at getNotFoundError (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:13:12)
gyp verb which failed at F (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:68:19)
gyp verb which failed at E (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:80:29)
gyp verb which failed at D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:89:16
gyp verb which failed at D:\Practice\webpack\Colt-youtube\my\node_modules\isexe\index.js:42:5
gyp verb which failed at D:\Practice\webpack\Colt-youtube\my\node_modules\isexe\windows.js:36:5
gyp verb which failed at FSReqCallback.oncomplete (fs.js:158:21)
gyp verb which failed C:\Users\Mustafa.windows-build-tools\python27\python.exe Error: not found: C:\Users\Mustafa.windows-build-tools\python27\python.exe
gyp verb which failed at getNotFoundError (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:13:12)
gyp verb which failed at F (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:68:19)
gyp verb which failed at E (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:80:29)
gyp verb which failed at D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:89:16
gyp verb which failed at D:\Practice\webpack\Colt-youtube\my\node_modules\isexe\index.js:42:5
gyp verb which failed at D:\Practice\webpack\Colt-youtube\my\node_modules\isexe\windows.js:36:5
gyp verb which failed at FSReqCallback.oncomplete (fs.js:158:21) {
gyp verb which failed stack: 'Error: not found: C:\Users\Mustafa.windows-build-tools\python27\python.exe\n' +
gyp verb which failed ' at getNotFoundError (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:13:12)\n' +
gyp verb which failed ' at F (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:68:19)\n' +
gyp verb which failed ' at E (D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:80:29)\n' +
gyp verb which failed ' at D:\Practice\webpack\Colt-youtube\my\node_modules\which\which.js:89:16\n' +
gyp verb which failed ' at D:\Practice\webpack\Colt-youtube\my\node_modules\isexe\index.js:42:5\n' +
gyp verb which failed ' at D:\Practice\webpack\Colt-youtube\my\node_modules\isexe\windows.js:36:5\n' +
gyp verb which failed ' at FSReqCallback.oncomplete (fs.js:158:21)',
gyp verb which failed code: 'ENOENT'
gyp verb which failed }
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. (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.js
npm 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!

I don't have access to those two links up above

Did you try upgrading your versions?

I'm having the same issue