FAIL ionic setup sass


#1

Hello,

I use last version of NodeJS.

I’m trying to use sass in a new ionic project on Windows 7 :

ionic start Demo blank
cd Demo
ionic setup sass

But i have problems for the last command (ionic setup sass) :

npmnpm WARN package.json demo@1.0.0 No license field.
npm WARN deprecated pangyp@2.3.2: use node-gyp@3+, it does all the things

node-sass@2.1.1 install D:\Datas\Samos\Mobile\Ionic\Demo\node_modules\gulp-sass\node_modules\node-sass
node scripts/install.js

Can not download file from https://raw.githubusercontent.com/sass/node-sass-binaries/v2.1.1/win32-ia32-node-4.0/binding.node

node-sass@2.1.1 postinstall D:\Datas\Samos\Mobile\Ionic\Demo\node_modules\gulp-sass\node_modules\node-sass
node scripts/build.js

gyp WARN install got an error, rolling back install
gyp ERR! configure error
gyp ERR! stack Error: 404 status code downloading 64-bit node.lib
gyp ERR! stack at Request. (D:\Datas\Samos\Mobile\Ionic\Demo\node_modules\gulp-sass\node_modules\node-sass\node_modules\pangyp\lib\install.js:403:20)
gyp ERR! stack at emitOne (events.js:82:20)
gyp ERR! stack at Request.emit (events.js:169:7)
gyp ERR! stack at Request.onRequestResponse (D:\Datas\Samos\Mobile\Ionic\Demo\node_modules\gulp-sass\node_modules\node-sass\node_modules\pangyp\node_modules\request\request.js:1255:10)
gyp ERR! stack at emitOne (events.js:77:13)
gyp ERR! stack at ClientRequest.emit (events.js:169:7)
gyp ERR! stack at HTTPParser.parserOnIncomingClient (_http_client.js:415:21)

gyp ERR! stack at HTTPParser.parserOnHeadersComplete (_http_common.js:88:23)

gyp ERR! stack at Socket.socketOnData (_http_client.js:305:20)
gyp ERR! stack at emitOne (events.js:77:13)
gyp ERR! System Windows_NT 6.1.7601
gyp ERR! command “C:\Program Files (x86)\nodejs\node.exe” “D:\Datas\Samos\Mobile\Ionic\Demo\node_modules\gulp-sass\node_modules\node-sass\node_modules\pangyp\bin\node-gyp” "rebuild"
gyp ERR! cwd D:\Datas\Samos\Mobile\Ionic\Demo\node_modules\gulp-sass\node_modules\node-sass
gyp ERR! node -v v4.0.0
gyp ERR! pangyp -v v2.3.2
gyp ERR! not ok
Build failed

Thanks for your help,

Samos


#2

For me it helped the following:

  1. Revert back to node 0.10.40 (use nvm or nvm-windows)
  2. delete the node_modules
  3. folder run npm update

it might work with 0.12.7 but I haven’t tested that option yet.

Also in sack overflow there’s a solution that uses npm rebuild node-sass

hope it helps


#3

Thank you very much, now it works with 0.12.7 :smile:

Samos