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] npm outdated ignores proxy and registry configs #2060

Closed
yousifalraheem opened this issue Oct 28, 2020 · 6 comments · Fixed by #2587 or #2591
Closed

[BUG] npm outdated ignores proxy and registry configs #2060

yousifalraheem opened this issue Oct 28, 2020 · 6 comments · Fixed by #2587 or #2591
Assignees
Labels
Bug thing that needs fixing Priority 1 high priority issue Release 7.x work is associated with a specific npm 7 release

Comments

@yousifalraheem
Copy link

Current Behavior:

Runing npm outdated will throw an error ignoring the proxy and registry configurations. After upgrading to npm 7, I was unable to run npm outdated anymore.

Expected Behavior:

Should work as intended showing the outdated dependencies.

Steps To Reproduce:

Steps to reproduce the behavior (You need to run this behind corporate VPN and registry):

  1. Set up the proxy and registry settings in the global npm config
  2. Navigate to any project with a valid package.json that has dependencies
  3. Run 'npm outdated'
  4. See error...

Environment:

  • OS: Windows 10 Version 1803 Build 17134.1792
  • Node: 15.0.1
  • npm: 7.0.5

Screenshots

image

@yousifalraheem yousifalraheem 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 Oct 28, 2020
@darcyclarke
Copy link
Contributor

@yousifalraheem can you try updating your version of v7 (ie. npm i -g npm@7) & trying again? We've fixed a few bugs around setting proxies.

@darcyclarke darcyclarke removed the Needs Triage needs review for next steps label Jan 15, 2021
@joshuaavalon
Copy link

@darcyclarke I am on npm 7.4.2 and Node 15 and I am still facing the same issue. I am behind a proxy. npm install and npm update works fine but npm outdated will throw getaddrinfo ENOTFOUND for registry.npmjs.org.

@thirteen-io
Copy link

@yousifalraheem can you try updating your version of v7 (ie. npm i -g npm@7) & trying again? We've fixed a few bugs around setting proxies.

I've just attempted this. Using npm i -g npm@7 fails however npm i -g npm@latest seems to have resolved the issue.
(Tested with v15.6.0 and v15.4.0 on Windows 10).

@ljharb
Copy link
Collaborator

ljharb commented Jan 19, 2021

@thirteen-io fails how? using “latest” right now installs npm 6.

@thirteen-io
Copy link

@ljharb Sorry for not being clear.
It failed exactly like the original issue posted. (ENOTFOUND etc)

You are also correct regarding the latest release... totally my mistake sorry. I thought latest was using npm 7. It is at least a temporary workaround for now if you absolutely need the outdated command.

@joshuaavalon
Copy link

@thirteen-io Using npm 6 is not a workaround if you want to use workspace which only available on npm 7. My workaround is npm-check-updates. It updates packages in package.json to latest version and I just diff the versions change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug thing that needs fixing Priority 1 high priority issue 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.

6 participants