Skip to content
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] Changing NPM version when on 7.23.0 ignores registry option #3758

Closed
1 task done
yacoman89 opened this issue Sep 15, 2021 · 0 comments · Fixed by #3760
Closed
1 task done

[BUG] Changing NPM version when on 7.23.0 ignores registry option #3758

yacoman89 opened this issue Sep 15, 2021 · 0 comments · Fixed by #3760
Labels
Bug thing that needs fixing Needs Triage needs review for next steps Release 7.x work is associated with a specific npm 7 release

Comments

@yacoman89
Copy link
Contributor

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

I use an internal network for development. Because of this, I have a mirror of the npm registry. After I updated npm to version 7.23.0 and attempted to downgrade npm to version 7.22.0 using npm install --global npm@7.22.0, I noticed the install would fail because npm was ignoring the registry I specified. This operation was forced to use the default registry https://registry.npmjs.org/npm during one of it's checks.

Expected Behavior

I would expect that if an alternative registry is provided, the npm install checks would use that registry and continue the install process.

Steps To Reproduce

  1. In this environment...
    a. Any OS without an internet connection that uses a mirror of the npm registry on an internal network.
    b. Need to be using npm version 7.23.0.
  2. With this config...
registry = "https://my.awesome.npm.mirror/npm"
  1. Run npm install --global npm@7.22.0
  2. See error...
npm ERR! code ENOTFOUND
npm ERR! syscall getaddrinfo
npm ERR! errno ENOTFOUND
npm ERR! network request to https://registry.npmjs.org/npm failed, reason getaddrinfo ENOTFOUND registry.npmjs.org
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'

Environment

  • OS: Any
  • Node: v12.14.0
  • npm: 7.23.0
@yacoman89 yacoman89 added Bug thing that needs fixing Needs Triage needs review for next steps Release 7.x work is associated with a specific npm 7 release labels Sep 15, 2021
@isaacs isaacs closed this as completed Sep 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug thing that needs fixing Needs Triage needs review for next steps Release 7.x work is associated with a specific npm 7 release
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants