npm_lazy icon indicating copy to clipboard operation
npm_lazy copied to clipboard

Cannot call method 'on' of undefined (Windows)

Open fresheneesz opened this issue 12 years ago • 2 comments

I ran the server, ran npm --registry http://localhost:8080 install on one of my packages, and the server crashed pretty quickly:

C:\Users\billy\Desktop\Stuff\git\npm_lazy>node server.js
npm_lazy at localhost port 8080
Forcing index refresh, last update: never max age: Mon Nov 04 2013 13:35:15 GMT-0800 (Pacific Standard Time)
Cache miss:  proto index.json , GET http://registry.npmjs.org/proto
Forcing index refresh, last update: never max age: Mon Nov 04 2013 13:35:15 GMT-0800 (Pacific Standard Time)
Cache miss:  imap index.json , GET http://registry.npmjs.org/imap

C:\Users\billy\Desktop\Stuff\git\npm_lazy\lib\cache.js:116
        res.on('error', function(err) {
            ^
TypeError: Cannot call method 'on' of undefined
    at C:\Users\billy\Desktop\Stuff\git\npm_lazy\lib\cache.js:116:13
    at ClientRequest.<anonymous> (C:\Users\billy\Desktop\Stuff\git\npm_lazy\node_modules\mixu_minimal\client.js:31:46)
    at ClientRequest.EventEmitter.emit (events.js:95:17)
    at Socket.socketOnEnd [as onend] (http.js:1569:9)
    at Socket.g (events.js:175:14)
    at Socket.EventEmitter.emit (events.js:117:20)
    at _stream_readable.js:920:16
    at process._tickCallback (node.js:415:13)

fresheneesz avatar Nov 04 '13 22:11 fresheneesz

I'm running on a Mac OX 10.9 and got exactly the same exception on a slightly different circumstance. See #8

jpbochi avatar Nov 05 '13 13:11 jpbochi

@fresheneesz #8 is now closed, IDK about releases but maybe run this again?

PixnBits avatar Jul 24 '14 21:07 PixnBits