node.js - npm error code EPEERINVALID while installing mongoose-auto-increment and mongoose-simpledb -


hi have encountered following error while installing npm package mongoose-auto-increment , mongoose-simpledb both globally , locally.

the error follows

mongoose-auto-increment

   npm warn peerdependencies peer dependency mongoose@~4.0.0       included mongoose-auto-increment no    npm warn peerdependencies longer automatically installed fulfill peerdependency     npm warn peerdependencies in npm 3+. application need depend on explicitly.    npm err! darwin 14.0.0    npm err! argv "node" "/usr/local/bin/npm" "install" "mongoose-auto-increment"    npm err! node v0.12.4    npm err! npm  v2.11.2    npm err! code epeerinvalid     npm err! peerinvalid package mongoose not satisfy siblings' peerdependencies requirements!    npm err! peerinvalid peer mongoose-auto-increment@4.0.0 wants mongoose@~4.0.0     npm err! please include following file support request:    npm err!     /users/febinp/downloads/shubham_application/project/npm-debug.log 

mongoose-simpledb

   npm err! darwin 14.0.0    npm err! argv "node" "/usr/local/bin/npm" "install" "mongoose-simpledb"    npm err! node v0.12.4    npm err! npm  v2.11.2    npm err! code epeerinvalid    npm err! peerinvalid package mongoose not satisfy siblings' peerdependencies requirements!    npm err! peerinvalid peer mongoose-auto-increment@4.0.0 wants mongoose@~4.0.0    npm err! peerinvalid peer mongoose-simpledb@4.0.3 wants mongoose@~3.8.18     npm err! please include following file support request:    npm err!     /users/febinp/downloads/shubham_application/project/npm-debug.log 

my package.json follows

{   "name": "project",   "private": true,   "version": "0.0.0",   "description": "a sails application",   "keywords": [],   "dependencies": {          "async": "^1.4.0",          "ejs": "~0.8.4",          "grunt": "0.4.2",          "grunt-contrib-clean": "~0.5.0",          "grunt-contrib-coffee": "~0.10.1",          "grunt-contrib-concat": "~0.3.0",          "grunt-contrib-copy": "~0.5.0",          "grunt-contrib-cssmin": "~0.9.0",          "grunt-contrib-jst": "~0.6.0",          "grunt-contrib-less": "0.11.1",          "grunt-contrib-uglify": "~0.4.0",          "grunt-contrib-watch": "~0.5.3",          "grunt-sails-linker": "~0.9.5",          "grunt-sync": "~0.0.4",          "include-all": "~0.1.3",          "mongoose": "^4.1.0",          "mongoose-acl": "^0.2.3",          "mongoose-unique-validator": "^0.4.1",          "passport-local-mongoose": "^1.0.1",          "rc": "~0.5.0",          "sails": "~0.11.0",          "sails-disk": "~0.10.0"   },  "scripts": {          "debug": "node debug app.js",          "start": "node app.js"  },  "main": "app.js",  "repository": {          "type": "git",          "url": "git://github.com/febinp/zatasa.git" },  "author": "xyz",  "license": "" } 

can me why getting error , workaround?

  1. in package.json mongoose have higher version 4.0.0. mongoose-simpledb wants mongoose@~3.8.18.

  2. mongoose-simpledb includes it's dependency mongoose-auto-increment. if explicitly declare _id field on schema type number simpledb automatically invoke mongoose-auto-increment plugin model.

example documentation itself:

exports.schema = {     _id: number, // causes simpledb auto-increment _id new documents.     creator: { type: number, ref: 'user' } }; 

i have tried changing package.json , worked:

{   "name": "project",   "private": true,   "version": "0.0.0",   "description": "a sails application",   "keywords": [],   "dependencies": {          "async": "^1.4.0",          "ejs": "~0.8.4",          "grunt": "0.4.2",          "grunt-contrib-clean": "~0.5.0",          "grunt-contrib-coffee": "~0.10.1",          "grunt-contrib-concat": "~0.3.0",          "grunt-contrib-copy": "~0.5.0",          "grunt-contrib-cssmin": "~0.9.0",          "grunt-contrib-jst": "~0.6.0",          "grunt-contrib-less": "0.11.1",          "grunt-contrib-uglify": "~0.4.0",          "grunt-contrib-watch": "~0.5.3",          "grunt-sails-linker": "~0.9.5",          "grunt-sync": "~0.0.4",          "include-all": "~0.1.3",          "mongoose": "~3.8.18",          "mongoose-simpledb": "~4.0.3",          "mongoose-acl": "^0.2.3",          "mongoose-unique-validator": "^0.4.1",          "passport-local-mongoose": "^1.0.1",          "rc": "~0.5.0",          "sails": "~0.11.0",          "sails-disk": "~0.10.0"   },  "scripts": {          "debug": "node debug app.js",          "start": "node app.js"  },  "main": "app.js",  "repository": {          "type": "git",          "url": "git://github.com/febinp/zatasa.git" }, "author": "xyz",  "license": "" } 

Comments

Popular posts from this blog

yii2 - Yii 2 Running a Cron in the basic template -

asp.net - 'System.Web.HttpContext' does not contain a definition for 'GetOwinContext' Mystery -

wso2esb - How to concatenate JSON array values in WSO2 ESB? -