Search code examples
npmnode-sass

Error installing node-sass dependency


I am trying to npm install a package.json with the following dependencies:

  "devDependencies": {
    "browser-sync": "^2.8.2",
    "del": "^1.2.0",
    "gulp": "^3.9.0",
    "gulp-autoprefixer": "^2.3.1",
    "gulp-babel": "^5.2.0",
    "gulp-concat": "^2.6.0",
    "gulp-eslint": "^1.0.0",
    "gulp-filesize": "0.0.6",
    "gulp-header": "^1.2.2",
    "gulp-imagemin": "^2.3.0",
    "gulp-jshint": "^1.11.2",
    "gulp-livereload": "^3.8.0",
    "gulp-minify-css": "^1.2.0",
    "gulp-newer": "^0.5.1",
    "gulp-notify": "^2.2.0",
    "gulp-plumber": "^1.0.1",
    "gulp-rename": "^1.2.2",
    "gulp-sass": "^2.0.4",
    "gulp-sourcemaps": "^1.5.2",
    "gulp-svgmin": "^1.2.0",
    "gulp-svgstore": "^5.0.4",
    "gulp-uglify": "^1.2.0",
    "imagemin-pngquant": "^4.1.2"
  },
  "dependencies": {
    "node-sass": "^3.2.0"
  }

But it fails with the node-sass package. A part of the output is this:

Cannot download "https://github.com/sass/node-sass/releases/download/v3.2.0/darwin-x64-51_binding.node": HTTP error 404 Not Found

And then:

node-sass@3.2.0 postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the node-sass@3.2.0 postinstall script 'node scripts/build.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the node-sass package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node scripts/build.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs node-sass
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls node-sass
npm ERR! There is likely additional logging output above.

Node version 7.5.0 and npm version 4.1.2, OSX Sierra

Any suggestions?


Solution

  • I had same issue using node 8.1.3. I solved downgrading to latest long term supported version of nodejs (now is the 6.11.0).

    The problem is that node-sass doesn't supports some nodejs versions....