Reputation: 49
I'm trying to clone one of my angular projects freshly. In order to make it work I have to do an npm install, which worked at some time. But now it fails with the following error:
npm install
npm ERR! code ECONNREFUSED
npm ERR! syscall connect
npm ERR! errno ECONNREFUSED
npm ERR! FetchError: request to http://localhost:8080/xmlbuilder/-/xmlbuilder-11.0.1.tgz failed, reason: connect ECONNREFUSED 127.0.0.1:8080
npm ERR! at ClientRequest.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\minipass-fetch\lib\index.js:97:14)
npm ERR! at ClientRequest.emit (node:events:376:20)
npm ERR! at Socket.socketErrorListener (node:_http_client:474:9)
npm ERR! at Socket.emit (node:events:388:22)
npm ERR! at emitErrorNT (node:internal/streams/destroy:188:8)
npm ERR! at emitErrorCloseNT (node:internal/streams/destroy:153:3)
npm ERR! at processTicksAndRejections (node:internal/process/task_queues:80:21)
npm ERR! FetchError: request to http://localhost:8080/xmlbuilder/-/xmlbuilder-11.0.1.tgz failed, reason: connect ECONNREFUSED 127.0.0.1:8080
npm ERR! at ClientRequest.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\minipass-fetch\lib\index.js:97:14)
npm ERR! at ClientRequest.emit (node:events:376:20)
npm ERR! at Socket.socketErrorListener (node:_http_client:474:9)
npm ERR! at Socket.emit (node:events:388:22)
npm ERR! at emitErrorNT (node:internal/streams/destroy:188:8)
npm ERR! at emitErrorCloseNT (node:internal/streams/destroy:153:3)
npm ERR! at processTicksAndRejections (node:internal/process/task_queues:80:21) {
npm ERR! code: 'ECONNREFUSED',
npm ERR! errno: 'ECONNREFUSED',
npm ERR! syscall: 'connect',
npm ERR! address: '127.0.0.1',
npm ERR! port: 8080,
npm ERR! type: 'system'
npm ERR! }
npm ERR!
npm ERR! If you are behind a proxy, please make sure that the
npm ERR! 'proxy' config is set properly. See: 'npm help config'
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\...\AppData\Local\npm-cache\_logs\2021-01-08T10_06_22_381Z-debug.log
I have no proxy configured, nor do I need one. In fact he downloaded some packages until this error appears:
https-proxy = null
proxy = null
registry = "http://registry.npmjs.org/"
I've tried to install it manually, it works without problems.
npm install xmlbuilder
I've tried this as admin and elevated. No success.
So why isn't it installed as dependency? Where does he get this localhost:8080 address from? There is definitely no server listening.
Regards
Upvotes: 2
Views: 1326
Reputation: 49
Found the problem. For any reason these localhost:8080 was set at some lines in package-lock.json. Deleting node_modules and package-lock.json made npm install work again.
Upvotes: 2