0

I have used session-mongoose(0.0.2) module in one of project. This is running on the top of node version v0.6.7. There is some recent changes in that, session-mongoose module try to pull the module mongoose which is compatible with node version(v0.6.19) on using command 'npm update' against my root package.json.

Because of session-mongoose and their dependencies are dynamically pull from npm registry on 'npm update' command, I can't control these.

Now the problem is system stop working in production on new deployment. Is there any way to resolve this without update node version?

And the error log is,

npm ERR! error rolling back [email protected] Error: UNKNOWN, unknown error 'C:\Pro gram Files\nodejs\node_builds\server\node_modules\session-mong oose\node_modules\mongeese\node_modules\mongoose' npm ERR! Unsupported npm ERR! Not compatible with your version of node/npm: [email protected] npm ERR! Required: {"node":">=0.6.19"} npm ERR! Actual: {"npm":"1.1.13","node":"0.6.7"} npm ERR! npm ERR! System Windows_NT 5.1.2600 npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nod ejs\\node_modules\\npm\\bin\\npm-cli.js" "update" npm ERR! cwd C:\Program Files\nodejs\node_builds\server npm ERR! node -v v0.6.7 npm ERR! npm -v 1.1.13 npm ERR! code ENOTSUP npm ERR! message Unsupported npm ERR! errno {} npm ERR! npm ERR! Additional logging details can be found in: npm ERR! C:\Program Files\nodejs\node_builds\server\npm-de bug.log npm not ok 

1 Answer 1

1
+50

You will have to update the node.js. Or else you will not be able to use packages recently released. Version 0.6.19 was released in June 2012. Since then many changes have been made. Recent stable version is 0.8.19.

When dealing with dependency you should use npm-shrinkwrap to lock the dependencies. http://blog.nodejs.org/2012/02/27/managing-node-js-dependencies-with-shrinkwrap/

Or you can freeze the project (dont do updates) once you plan to deploy it.

Sign up to request clarification or add additional context in comments.

3 Comments

Even though the current stable release of node is 0.8.x. Updating from 0.6.7 to 0.6.19 (at least) is a minor update. Actually not a minor update in the semver pattern, just a build update.
Yes, a minor update(or patch update in semantic version), but most importantly they have added extra API, without changing existing API. So you should be able to run without changing your code.
@user568109 But npm update commant still has issue. Anyway Thank you dude.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.