failed to fetch from registry: express on windows #2092

hanskishore opened this Issue Jan 25, 2012 · 5 comments


None yet
5 participants

info it worked if it ends with ok
verbose cli [ 'C:\Program Files (x86)\nodejs\node.exe',
verbose cli 'C:\Program Files (x86)\nodejs\node_modules\npm\bin\npm-cli.js',
verbose cli 'install',
verbose cli '-g',
verbose cli 'express' ]
info using npm@1.1.0-beta-10
info using node@v0.6.7
verbose config file C:\Users\kpatil.npmrc
verbose config file C:\Program Files (x86)\nodejs\etc\npmrc
verbose config file C:\Program Files (x86)\nodejs\node_modules\npm\npmrc
WARN invalid config registry="http:/\"
WARN invalid config Must be a full url with 'http://'
verbose mkdir done: C:\Users\kpatil\AppData\Roaming\npm 755
verbose into C:\Users\kpatil\AppData\Roaming\npm [ 'express' ]
verbose cache add express
verbose cache add [ 'express', null ]
silly cache add: name, spec, args [ undefined, 'express', [ 'express', null ] ]
verbose parsed url { pathname: 'express', path: 'express', href: 'express' }
verbose addNamed [ 'express', '' ]
verbose addNamed [ null, '' ]
silly name, range, hasData [ 'express', '', false ]
verbose raw, before any munging express
verbose url resolving [ '', './express' ]
verbose url resolved
http GET
ERR! Error: failed to fetch from registry: express
ERR! at C:\Program Files (x86)\nodejs\node_modules\npm\lib\utils\npm-registry-client\get.js:139:12
ERR! at cb (C:\Program Files (x86)\nodejs\node_modules\npm\lib\utils\npm-registry-client\request.js:32:9)
ERR! at Request._callback (C:\Program Files (x86)\nodejs\node_modules\npm\lib\utils\npm-registry-client\request.js:137:18)
ERR! at Request.callback (C:\Program Files (x86)\nodejs\node_modules\npm\node_modules\request\main.js:104:22)
ERR! at Request. (C:\Program Files (x86)\nodejs\node_modules\npm\node_modules\request\main.js:181:58)
ERR! at Request.emit (events.js:88:20)
ERR! at ClientRequest. (C:\Program Files (x86)\nodejs\node_modules\npm\node_modules\request\main.js:178:10)
ERR! at ClientRequest.emit (events.js:67:17)
ERR! at CleartextStream. (http.js:1127:11)
ERR! at CleartextStream.emit (events.js:67:17)
ERR! Report this entire log at:
ERR! or email it to:
ERR! System Windows_NT 6.1.7601
ERR! command "C:\Program Files (x86)\nodejs\node.exe" "C:\Program Files (x86)\nodejs\node_modules\npm\bin\npm-cli.js" "install" "-g" "express"
ERR! cwd C:\Users\kpatil\Desktop\Notepad2
ERR! node -v v0.6.7
ERR! npm -v 1.1.0-beta-10
ERR! message failed to fetch from registry: express
verbose exit [ 1, true ]

Any idea why this is happening


mfncooper commented Feb 5, 2012

It looks like you tried to configure a non-https URL but npm didn't like the string you provided. Note the WARN entries for the config, followed by npm using the default https value instead of the config entry it did not like. If you need to use a non-https value, you might try specifying it on the command line to verify that it works, like so:

npm install -g express --registry

and if that does work, setting that value as the default with:

npm config set registry

mcandre commented Feb 17, 2012

Strangely, neither command works for me.

C:\>node --version

C:\>npm --version

C:\>npm install -g roman --registry
npm http GET

npm ERR! Error: failed to fetch from registry: roman
npm ERR!     at C:\Program Files (x86)\nodejs\node_modules\npm\lib\utils\npm-registry-client\get.js:139:12
npm ERR!     at cb (C:\Program Files (x86)\nodejs\node_modules\npm\lib\utils\npm-registry-client\request.js:32:9)
npm ERR!     at Request._callback (C:\Program Files (x86)\nodejs\node_modules\npm\lib\utils\npm-registry-client\request.js:137:18)
npm ERR!     at Request.callback (C:\Program Files (x86)\nodejs\node_modules\npm\node_modules\request\main.js:109:22)
npm ERR!     at Request.<anonymous> (C:\Program Files (x86)\nodejs\node_modules\npm\node_modules\request\main.js:198:58)
npm ERR!     at Request.emit (events.js:88:20)
npm ERR!     at ClientRequest.<anonymous> (C:\Program Files (x86)\nodejs\node_modules\npm\node_modules\request\main.js:356:14)
npm ERR!     at ClientRequest.emit (events.js:67:17)
npm ERR!     at HTTPParser.onIncoming (http.js:1261:11)
npm ERR!     at HTTPParser.onHeadersComplete (http.js:102:31)
npm ERR! You may report this log at:
npm ERR!     <>
npm ERR! or email it to:
npm ERR!     <>
npm ERR!
npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:\\Program Files (x86)\\nodejs\\\\node.exe" "C:\\Program Files (x86)\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "-g" "roman" "--registry" ""
npm ERR! cwd C:\
npm ERR! node -v v0.6.11
npm ERR! npm -v 1.1.1
npm ERR! message failed to fetch from registry: roman
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR!     C:\npm-debug.log
npm not ok

its actully behind the proxy that's causing this issue..


ralt commented Mar 9, 2013

So this issue should be closed ;o)

luk- closed this Mar 9, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment