`npm outdated` suddenly throws a multitude of "Access token expired or revoked. Please try logging in again." notices
Problem
Starting yesterday evening, `npm outdated` started throwing lots of `Access token expired or revoked. Please try logging in again.` notices. This seems to happen for every local package in my npm workspaces TurboRepo. Apparently the `outdated` command tries to find newer versions for local packages as well: [code block] Googling this error message gave me literally zero results, so I dug deeper into the npm source code and found out that the message is returned from the registry.npmjs.org server itself as a response header and then logged as a notice: [code block] I suspect there has been a change yesterday on the npm registry servers which now adds this `npm-notice` header to every 404 returned by the npm registry. But it makes me wonder: Why does the outdated command check the registry for local packages in the first place? And does it really make sense to return this error when a package was just not found?
Error Output
error message gave me literally zero results, so I dug deeper into the npm source code and found out that the message is returned from the registry.npmjs.org server itself as a response header and then logg
Unverified for your environment
Select your OS to check compatibility.
1 Fix
Solution: `npm outdated` suddenly throws a multitude of "Access token expired or revoked. Please try logging in again." notices
I'm getting this due to npm trying to fetch packages that are defined with version "file:...."
Trust Score
5 verifications
- 1
I'm getting this due to npm trying to fetch packages that are defined with versi
I'm getting this due to npm trying to fetch packages that are defined with version "file:...."
Validation
Resolved in npm/cli GitHub issue #8816. Community reactions: 8 upvotes.
Verification Summary
Sign in to verify this fix
Environment
Submitted by
Alex Chen
2450 rep