erming / shout

Deprecated. See fork @ https://github.com/thelounge
MIT License
3.63k stars 273 forks source link

Can not get shout by npm #656

Open Yanhao opened 8 years ago

Yanhao commented 8 years ago

when I run ’npm install shout -g', I get the following same errors on my two different computers(one server, one PC). And I am sure that I'm not behind a proxy.

` npm WARN deprecated CSSselect@0.4.1: the module is now available as 'css-select' npm WARN deprecated CSSwhat@0.4.7: the module is now available as 'css-what' npm ERR! fetch failed http://github.com/component/emitter/archive/1.0.1.tar.gz npm WARN retry will retry, error on last attempt: Error: read ECONNRESET npm ERR! fetch failed http://github.com/component/emitter/archive/1.0.1.tar.gz npm WARN retry will retry, error on last attempt: Error: read ECONNRESET npm ERR! fetch failed http://github.com/component/emitter/archive/1.0.1.tar.gz npm ERR! Linux 3.10.0-123.4.4.el7.x86_64 npm ERR! argv "/root/git/nvm/versions/node/v5.8.0/bin/node" "/root/git/nvm/versions/node/v5.8.0/bin/npm" "install" "shout" "-g" npm ERR! node v5.8.0 npm ERR! npm v3.7.3 npm ERR! code ECONNRESET npm ERR! errno ECONNRESET npm ERR! syscall read

npm ERR! network read ECONNRESET npm ERR! network This is most likely not a problem with npm itself npm ERR! network and is related to network connectivity. npm ERR! network In most cases you are behind a proxy or have bad network settings. npm ERR! network npm ERR! network If you are behind a proxy, please make sure that the npm ERR! network 'proxy' config is set properly. See: 'npm help config'

npm ERR! Please include the following file with any support request: npm ERR! /root/npm-debug.log `

Yanhao commented 8 years ago

the url http://github.com/component/emitter/archive/1.0.1.tar.gz should be https://github.com/component/emitter/archive/1.0.1.tar.gz Right?

astorije commented 8 years ago

I can npm install shout just fine (haven't tried in global mode though). Are you still affected by this issue? Can you try npm install shout in a temporary folder?

Yanhao commented 8 years ago

@astorije It still doesn‘t work, and I believe it is because the url of package emmiter using http instead of https. shout is dependent on socket.io-parser, socket.io-parser is dependent on emmiter.

this picture is the output of command "npm show socket.io-parser@2.1.2 http://img.vim-cn.com/47/a0153f5a39173e105a87a2e64267a91e86d34b.png

astorije commented 8 years ago

I don't see how the http/https schemes can be an issue, because GitHub is serving this tarball just fine over http. I note that socket.io-parser has updated their package.json file to fetch from npm instead in version 2.2.1. A few tests then:

If this is indeed an issue with http/https, I'm truly puzzled, because it never occurred to me. Any chance this could come from settings at your network/router level? For example, the facts that Travis CI passed on master 20 days ago and that I can run npm install shout fine are indications to me that it could come from your side. Maybe at the OS level too?

Yanhao commented 8 years ago

Yes, I have tried without -g option,but it doesn't help. I am running ArchLinux on my laptop and centos7 on my server.

I can run ‘npm install socket.io-parser@2.2.1’ and ’npm install thelounge‘ successfully.

T^T

astorije commented 8 years ago

I can't think of anything else than a network-related issue then :-/ I have tried with different OSes in different networks and so far couldn't reproduce.

If someone else gets this, please shout!

robertsknutzen commented 7 years ago

I'm getting the same issue. I'm trying to do this in a container but I can try bare metal if someone needs me to. Strangely i cannot get the tarball over http i have to use https

using a ubuntu 16.04 container

robert@shout2:~$ sudo npm -g install shout
npm WARN deprecated CSSselect@0.4.1: the module is now available as 'css-select'
npm WARN deprecated CSSwhat@0.4.7: the module is now available as 'css-what'
npm ERR! code ECONNRESET
npm ERR! errno ECONNRESET
npm ERR! network request to http://github.com/component/emitter/archive/1.0.1.tar.gz failed, reason: socket hang up
npm ERR! network This is a problem related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settings.
npm ERR! network 
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly.  See: 'npm help config'

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/robert/.npm/_logs/2017-08-18T04_35_00_933Z-debug.log
robert@shout2:~$ curl http://github.com/component/emitter/archive/1.0.1.tar.gz
curl: (56) Recv failure: Connection reset by peer

debug log https://pastebin.com/U0H01n4Q

I have confirmed that I can't get the tar.gz over cleartext. Running it on a different machine (same internet connection) I get

curl http://github.com/component/emitter/archive/1.0.1.tar.gz
curl: (56) Recv failure: Connection reset by peer

I have basically no experience with npm/node so i'm not sure what to do at this point.

I think you are likely right that this is likely a network issue. Not sure why i'm one of the lucky few who can't get emitter over clear text :\

EDIT: It might be worth noting that the first time i ran ' sudo npm -g install shout' I let it run for about 16 hours (went to bed, went to work, came home and remembered I should be able to use shout) and it was hanged on the part where it gets emitter. No error.

MaxLeiter commented 7 years ago

hey @robertsknutzen, just a note Shout is inactive and you can find a community updated fork over here: https://github.com/thelounge/lounge. Not 100% sure it will fix your issue, but you'll at least get support :)

feel free to hop on #thelounge on freenode to chat if you have any questions.