-
Notifications
You must be signed in to change notification settings - Fork 3.4k
[BUG] npm install gets stuck on 'idealTree:lib: sill idealTree buildDeps' #4309
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I have the same issue, when trying to install a package globally or locally. I am also running Arch Linux. The command eventually fails with ETIMEDOUT as follows:
The log suggests a problem trying to access EDIT: I started tinkering with
So, rolling back to v16 might work as a temporary solution, while the issue remains unresolved with node v17. Environment
; node bin location = /usr/bin/node
; cwd = /home/tracert6
; HOME = /home/tracert6
; Run `npm config ls -l` to show all defaults. |
i think we need more information to reproduce this one. first off, can you give things a try with npm 8.5.3 and see if you still have problems? if you do, can you share the |
@MatiasDuhalde your issue looks to be a problem with ipv6 as you have a timeout occurring during the socket connection. i've seen this happen myself on occasion and have raised the issue internally for investigation with the registry team. can you try running
and see if you get a response? |
Hey @nlf ! Thanks for the reply! Using npm
The complete log:
I ran the command you suggested in Arch Linux, but got no response. I tried same command in Debian in the same network, and got a |
this is an underlying problem in your arch linux installation it seems. if the above |
Not sure if relevent, but I gave the curl command some time to complete, but it didn't give any results. I don't have ipv6, though. The issue I had seems to be resolved, though. npm install works again! I'll close this issue |
In my case the problem was in my server's DNS. Once I changed it to Google's installation went fine. |
I'm on |
I had this problem some time ago, and just as @nlf suggested here #4309 (comment), it was related to my IPv6 stack configuration, and the problem was not limited to the npm registry, but also extended to the communication with other services that use IPv6, as I could diagnose later. Also, in my personal case, the problem was not exactly my OS, but my local network router. After tinkering some time with the router configuration, I could make it work. Unfortunately I can't give more insight on how, since I can't recall the settings I modified, and I'm not very skilled in networking. |
In my case being behind a VPN was causing this issue, I disconnected and it ran just fine |
Had this issue just now, also behind a VPN like Mariano. Fixed by simply restarting connection to Wifi |
It worked for me when I changed to another Wifi. |
|
I reconnect my wifi and it worked back |
Updating registry works for me. |
change the registry will help, we should set registry manually since it's stucked. |
For me work disable the IPV6 in the ethernet |
You should fix your IPv6, not disable it. |
Signing into my VPN fixed this for me. No clue why |
Same things happen here. I built a VPN service myself. Unfortunately my server provider - kamatera does not support IPv6 right now. So I have to switch another provider to finish the installation of the package. Thanks @nlf for the hint. |
had the same issue on windows 11. npm vsrsions 18-19, restarting my pc solve the problem. |
In my case the problem persisted after vpn disconnection. Manually flushing the routing table fixed it. |
npm install -g registry.npmjs.org npm config set registry https://registry.npmjs.org --global Worked for me. |
That first command should not be needed at all, and installs a package you won’t be using. |
My router changed my DNS settings without me knowing and that was the root cause... If you make it this far in the thread and are still having issues, check your DNS settings!!!!!@nlf you saved me with this comment 🙌 that tipped me off that the issue had nothing to do with npm |
Brand new M1 Mac Pro, fresh curl install of nvm and node confirmed. When running Tried the MacOS trick: IPv6 Automatically -> Link-Local Only, did not work.
Also noting that after the curl install I created a
This did nothing and each new terminal requires me to run I also disabled the macOS Ventura 13.3.1 Firewall. Waited around a half hour for something to happen, and got a socket timeout error eventually. Still searching for a solution here |
on the same boat as @jacobmakarsky. Frustrsating |
I have the same problem, I have no additional settings regarding my DNS in my IPv6. I also have no problems with running curl. I can't get any error log, it just stays in an infinite load. I also changed the registry but still the same behavior. Just when I try to download the library it stays stuck indefinitely. |
@KougamiJuan another thing that's potentially worth trying is your auth... try |
Update: I did Btw, I then got nvm to load in on each new terminal by creating a |
This worked for me, too. Thank you. |
I forgot to comment here but doing this worked. I'm really confused. Why did it work when I did this? Was it because of some setting I had and didn't know? |
@KougamiJuan dude I wish I could tell you... none of this makes sense to me. That worked briefly and then it broke again for me yesterday 🤷♂️ |
Probably because the VPN instead of supporting IPv6 simply blocks IPv6 traffic? So npm still resolves AAAA records, although no connection to IPv6 destinations is possible. Which VPN provider is it if I may ask? |
I also had this issue, I managed to resolve my issues by installing protonvpn and using the vpn. |
@treysis my DNS provider is Spectrum, same with another dev who commented on a related post; I know you were asking about vpns but figured that context might help as well |
Actually, the DNS provider is irrelevant. The OS can request any DNS record type from DNS it wants. |
Work for me too on Windows |
You shouldn't disable IPv6 as it might cause other problems. Also Microsoft strongly discourages disabling it. |
Setting from system wasnt enough so had to set Ipv4 from router settings and it worked! |
Possible Solution for MacOS usersThis is really a difficult problem I have been struggling with for months. Often, I switched to node v16, installed my packages, and switched back to v18. At some point, I realized that I only get this issue in my home WiFi - not in the office or via my smartphone's hotspot. This issue as well as #4163 helped me realise that it must be related to IPv6. I visited https://test-ipv6.com and the analysis reported that IPv6 is not working at all for me. Things like Other Ideas For YouIf this doesn't work for you (or you're not on MacOS), you might wanna try the following solutions/ hacks:
|
I was able to resolve by upgrading to node 20.9.0 and npm 10.1.0 |
In my case after troubleshooting for a day and half what I did was to completely uninstall the existing version of node and npm I had on my system then, I downloaded a newer version of node (Recommended for most users) which has npm package embedded. Restarted my system after installation and guess what? It worked! |
thanks! work for me. |
(windows) Nothing works for me.
If i set strict-ssl to false, npm works. OFC I don't want to use this option. |
Is there an existing issue for this?
This issue exists in the latest npm version
Current Behavior
When I run
npm install
in some repository, like https://github.com/mozilla/pdf.js, it gets stuck at the step: 'idealTree:lib: sill idealTree buildDeps'.Other things like
npm -g install
don't work either.Below is the verbose output and debug log attached.
npm-verbose.txt
2022-01-21T23_07_33_102Z-debug-0.log
Expected Behavior
It should install the neccesary packages
Steps To Reproduce
npm install -g gulp-cli
(or any other package presumably)Environment
The text was updated successfully, but these errors were encountered: