Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[BUG] npm config get prefix super slow #1243

Closed
DullReferenceException opened this issue May 4, 2020 · 5 comments
Closed

[BUG] npm config get prefix super slow #1243

DullReferenceException opened this issue May 4, 2020 · 5 comments
Assignees
Labels
Bug thing that needs fixing Release 6.x work is associated with a specific npm 6 release

Comments

@DullReferenceException
Copy link

What / Why

This is an attempt to resurrect this unresolved bug: npm/npm#14458

For some reason, the command npm config get prefix is multi-seconds slow. This normally wouldn't bother me, but for users of nvm like me, this is really impacting since it uses this command internally, and nvm is used in shell startup scripts. See nvm-sh/nvm#782 for more details. Therefore, shell startup is super slow, especially for those using WSL.

When

Always

Where

NPM CLI

How

Current Behavior

Run time npm config get prefix, see multi-second response timing.

Steps to Reproduce

Run npm config get prefix

Expected Behavior

Result should come back quicker.

Who

?

References

@ljharb
Copy link
Contributor

ljharb commented May 4, 2020

cc @darcyclarke; this actually would make a ton of difference for every nvm user, including every travis-ci run.

@darcyclarke
Copy link
Contributor

🤔 I'm positive there's some digging to be done here

@darcyclarke darcyclarke self-assigned this May 4, 2020
@darcyclarke darcyclarke added Bug thing that needs fixing Release 6.x work is associated with a specific npm 6 release labels May 4, 2020
@EdwardLuke
Copy link

Has any progress been made with this? I would be interested in helping with this issue.

@IdsTeepe
Copy link

IdsTeepe commented Jul 4, 2020

Recently, npm config get prefix has been very slow on my machine. This seems to be ever since I moved the /var/ directory from my SSD to my HDD to free up some space.
The first time the command runs (as part of my .bashrc script) it is especially slow, taking somewhere between 10-20 seconds. Later runs (by opening new shells) it 'only' takes a few seconds.

@darcyclarke
Copy link
Contributor

npm v6 is no longer in active development; We will continue to push security releases to v6 at our team's discretion as-per our Support Policy.

If your bug is preproducible on v7, please re-file this issue using our new issue template.

If your issue was a feature request, please consider opening a new RRFC or RFC. If your issue was a question or other idea that was not CLI-specific, consider opening a discussion on our feedback repo

Closing: This is an automated message.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Bug thing that needs fixing Release 6.x work is associated with a specific npm 6 release
Projects
None yet
Development

No branches or pull requests

5 participants