-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
[BUG] all npm commands hang after 1 week? #3163
Comments
The fact that it's hanging after 7 days is a very strong indicator that it has to do with the update notifier. (Ie, the bit where npm checks for a new version of npm, and nags you to upgrade.) As a workaround, you can try running with But..... why is that request hanging? That's very strange. |
Thanks for that info, that's helpful! Is there any logic changes for the update notifier in npm 7? Because we are not seeing this issue in our images using npm 6 Also can I ask which domain is this update notifier hitting? Is it going to try fetching |
the update notifier was replaced entirely for npm 7, and yes it does fetch from |
Interesting, that domain already exists in our proxy's whitelist 🤔 Oh and a bit of more details, we also tried if we get a shell of the running container which stuck in the middle of the script and run |
that's very interesting.. i wonder if we're doing something strange when we don't have a tty. we'll look into it further and see what we can find |
we also had problems with the update check because our company uses a private registry, which is used when building in the live system we use the "npm run" command to start the server until the time i found this article we had no idea why it requests the registry and hangs on the "run" command our fix now is to disable this update check in the .npmrc, however this was completely unexpected from our side^^ -> we have noticed this by the way, since we switched from npm 6 to 7 | nodejs 14 to16 |
This was fixed by #3348 and published in |
Background: we are using quay.io to build docker images for our applications. We have some
npm ...
commands in the startup script when a container has been brought up.Recently after upgrading to npm 7, we start to notice that some of our containers are stuck at booting up, more specifically they stuck at the first attempt to run any
npm ...
commands in that startup script.After further invistigation we found that rebuild the images in quay seems to be able to get rid of the problem, but just temporarily. After 7 days, the same image will get stuck again at the first attempt to run any
npm ...
commandsOur older images, those who were still using npm 6, does not have any similar issues
So basically right now we are scratching our heads trying to figure out why is this happening. Any insight on this matter is appreciated
Current Behavior:
Run an example startup script when docker container is spinning up
Output
Expected Behavior:
npm commands should not hang
Steps To Reproduce:
Really not sure if it is easy to reproduce by you because on our end this issue will only happen on images that has been build 1 week before or older. But please let me know if there is anything I can help with you in order to verify this issue.
Environment:
The text was updated successfully, but these errors were encountered: