Npm install: grunt does not satisfy its siblings' peerDependencies requirements
RocAlayo opened this issue · 20 comments
I just created a new app and npm install
doesn't succeed installing all the dependencies, I get this:
npm ERR! peerinvalid The package grunt does not satisfy its siblings' peerDependencies requirements!
npm ERR! peerinvalid Peer grunt-contrib-copy@0.5.0 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-express-server@0.4.17 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-karma@0.8.3 wants grunt@0.4.x
npm ERR! peerinvalid Peer jit-grunt@0.5.0 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-contrib-clean@0.5.0 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-newer@0.7.0 wants grunt@~0.4.1
npm ERR! peerinvalid Peer grunt-usemin@2.1.1 wants grunt@>=0.4.0
npm ERR! peerinvalid Peer grunt-concurrent@0.5.0 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-contrib-concat@0.4.0 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-contrib-htmlmin@0.2.0 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-contrib-sass@0.7.3 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-asset-injector@0.1.0 wants grunt@~0.4.1
npm ERR! peerinvalid Peer grunt-ng-annotate@0.2.3 wants grunt@~0.4.1
npm ERR! peerinvalid Peer grunt-autoprefixer@0.7.6 wants grunt@~0.4.2
npm ERR! peerinvalid Peer grunt-bower-install@1.4.1 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-contrib-watch@0.6.1 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-node-inspector@0.1.5 wants grunt@~0.4.2
npm ERR! peerinvalid Peer grunt-svgmin@0.4.0 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-contrib-cssmin@0.9.0 wants grunt@~0.4.1
npm ERR! peerinvalid Peer grunt-contrib-jshint@0.10.0 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-dom-munger@3.4.0 wants grunt@~0.4.1
npm ERR! peerinvalid Peer grunt-contrib-uglify@0.4.1 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-protractor-runner@1.1.0 wants grunt@~0.4.1
npm ERR! peerinvalid Peer grunt-nodemon@0.2.1 wants grunt@~0.4.1
npm ERR! peerinvalid Peer grunt-contrib-imagemin@0.7.1 wants grunt@^0.4.0
Before creating the app I updated all the packages in NPM so when I check my version of GruntJS I get this:
$ npm -g list grunt
npm WARN unmet dependency /usr/local/lib/node_modules/bower/node_modules/insight requires chalk@'^0.5.0' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/bower/node_modules/chalk,
npm WARN unmet dependency which is version 0.5.1
npm WARN unmet dependency /usr/local/lib/node_modules/bower/node_modules/update-notifier requires chalk@'^0.5.0' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/bower/node_modules/chalk,
npm WARN unmet dependency which is version 0.5.1
npm WARN unmet dependency /usr/local/lib/node_modules/generator-angular-fullstack/node_modules/yo requires yeoman-generator@'^0.17.1' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/generator-angular-fullstack/node_modules/yeoman-generator,
npm WARN unmet dependency which is version 0.17.2
npm WARN unmet dependency /usr/local/lib/node_modules/generator-angular-fullstack/node_modules/yeoman-generator/node_modules/download/node_modules/decompress/node_modules/extname requires map-key@'^0.1.1' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/generator-angular-fullstack/node_modules/yeoman-generator/node_modules/download/node_modules/decompress/node_modules/map-key,
npm WARN unmet dependency which is version 0.1.4
npm WARN unmet dependency /usr/local/lib/node_modules/generator-angular-fullstack/node_modules/generator-ng-component/node_modules/yeoman-generator/node_modules/download/node_modules/decompress/node_modules/extname requires map-key@'^0.1.1' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/generator-angular-fullstack/node_modules/generator-ng-component/node_modules/yeoman-generator/node_modules/download/node_modules/decompress/node_modules/map-key,
npm WARN unmet dependency which is version 0.1.4
npm WARN unmet dependency /usr/local/lib/node_modules/generator-angular-fullstack/node_modules/yo/node_modules/update-notifier requires chalk@'^0.5.0' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/generator-angular-fullstack/node_modules/yo/node_modules/chalk,
npm WARN unmet dependency which is version 0.5.1
npm WARN unmet dependency /usr/local/lib/node_modules/gulp/node_modules/gulp-util requires chalk@'^0.5.0' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/gulp/node_modules/chalk,
npm WARN unmet dependency which is version 0.5.1
npm WARN unmet dependency /usr/local/lib/node_modules/yo/node_modules/update-notifier requires chalk@'^0.5.0' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/yo/node_modules/chalk,
npm WARN unmet dependency which is version 0.5.1
npm WARN unmet dependency /usr/local/lib/node_modules/yo/node_modules/yeoman-generator/node_modules/download/node_modules/decompress/node_modules/extname requires map-key@'^0.1.1' but will load
npm WARN unmet dependency /usr/local/lib/node_modules/yo/node_modules/yeoman-generator/node_modules/download/node_modules/decompress/node_modules/map-key,
npm WARN unmet dependency which is version 0.1.4
/usr/local/lib
└── grunt@0.4.5
I supose I have a problem with all that npm WARN unmet dependency
but I don't know how to fix it.
Try npm cache clean
and try install again.
Same as before. Although tasks of grunt seem to work correctly, I tried grunt serve
and grunt build
and they work fine.
Strange. Try npm install -g npm yo bower
Otherwise stackoverflow would be your best bet.
Now I have a new set of errors but I realize that this errors doesn't have anything to do with the generator so thanks for your help I will search in stackoverflow.
Yeah, I'm getting the same error all of the time. No idea what's the cause, but I'm quite sure it isn't this generator. I'd be glad to hear a solution, if someone has it, though :)
I finally fixed it by uninstalling node, npm and all the configurations that they saved in my mac and reinstalling it afterwards. Now is working fine. This post in stackoverflow helped me to find all the pieces that node leave in the system. :)
FYI : I had the same problem and resolved it by running a :
brew update
brew upgrade
npm remove -g grunt
and removing my Grunt, Bower local directories.
and re-installing it all.
Didn't have the time to find precisely where it came from.
Hope it helps.
I also had this problem and the following worked for me
npm update -g
I'm assuming that uninstalling everything and then re-installing is probably accomplishing something along the same lines.
@droidenator worked for me too ... thanks for that
npm update -g
worked for me, thanks.
I got similar error when I run grunt install
on Bamboo. By adding "grunt": "~0.4.5"
into the dependencies section in package.json, it was fixed.
both, npm cache clean
and npm update -g
worked for me. Thanks.
This is the best solution.
npm cache clean
npm update -g
None of these solutions worked for me. Still the same crap.
I'm having this issue running imageoptim. I haven't been able to figure it out after trying everything mentioned above.
This is getting frustrating because absolutely NOTHING is working. Why on earth was this garbage pushed out!? :<
Something that worked for me was running:
npm install grunt@~0.4.0
I had to
npm remove grunt
npm install grunt@~1.0.1
If I didn't specify the version with the ~, it wouldn't work
I changed grunt-sass version inside package.json to ^3.0.0 but failed then with ^2.0.0 it worked