node.js - Updated node on my system, now grunt won't run in npm project -


i updated node on computer 0.12.4. , seems have done project i’m working inside node.js express.js. near can tell there appears come kind of compatibility issue between version of node i’m running , node_modules. used git go previous versions of project (versions worked fine) , don’t work either.

my computer running: osx yosemite 10.10.3 node: 0.12.4 npm: 2.11.3

my project’s dependancies in package.json file:

    "dependencies": {       "body-parser": "~1.8.1",       "cookie-parser": "~1.3.3",       "debug": "~2.0.0",       "express": "~4.9.0",       "grunt": "^0.4.5",       "grunt-sass": "^0.17.0",       "jade": "~1.6.0",       "morgan": "~1.3.0",       "node-sass": "^1.2.3",       "serve-favicon": "~2.1.3"     },     "devdependencies": {       "grunt-contrib-watch": "^0.6.1"     } 

the problem: when run grunt in terminal errors telling me:

    loading "sass.js" tasks...error     >> error: cannot find module 'node-sass'     warning: task "sass" not found. use --force continue. 

so removed node_modules , ran npm install in terminal , more errors:

    error: module did not self-register.       @ error (native)       @ module.load (module.js:355:32)       @ function.module._load (module.js:310:12)       @ module.require (module.js:365:17)       @ require (module.js:384:17)       @ object.<anonymous> (/users/sheynawatkins/dev/node/lola/node_modules/node-sass/lib/index.js:181:15)       @ module._compile (module.js:460:26)       @ object.module._extensions..js (module.js:478:10)       @ module.load (module.js:355:32)       @ function.module._load (module.js:310:12)     npm err! darwin 14.3.0     npm err! argv "node" "/usr/local/bin/npm" "install"     npm err! node v0.12.4     npm err! npm  v2.11.3     npm err! code elifecycle      npm err! node-sass@1.2.3 postinstall: `node scripts/build.js`     npm err! exit status 1     npm err!      npm err! failed @ node-sass@1.2.3 postinstall script 'node scripts/build.js'.     npm err! problem node-sass package,     npm err! not npm itself.  

what should do?

you're using ancient version of node-sass (^1.2.3, while current version 3.2.0), try installing more recent version (which installs fine me node 0.12):

$ npm node-sass@latest --save 

Comments

Popular posts from this blog

How has firefox/gecko HTML+CSS rendering changed in version 38? -

javascript - Complex json ng-repeat -

jquery - Cloning of rows and columns from the old table into the new with colSpan and rowSpan -