Shields: Scoped NPM Badge Invalid

Created on 16 Jun 2020  路  11Comments  路  Source: badges/shields

Are you experiencing an issue with...

  • [x] [shields.io](https://shields.io/#/)
  • [ ] My own instance
  • [ ] [badge-maker NPM package](https://www.npmjs.com/package/badge-maker)

:beetle: Description

The NPM package version badge for my package @freddyheppell/random-prime is now showing invalid, when it should be showing the latest version 1.2.2

:link: Link to the badge

https://img.shields.io/npm/v/@freddyheppell/random-prime

:bulb: Possible Solution

needs-upstream-help operations

Most helpful comment

We believe this to be fixed - please let me know if you're still having problems.

All 11 comments

The endpoint we call for these badges is
https://registry.npmjs.org/-/package/@freddyheppell%2Frandom-prime/dist-tags
which is returning a 401 Unauthorized.
We seem to be getting the same result on other packages with scope e.g:
https://registry.npmjs.org/-/package/@cycle%2Fcore/dist-tags
but its working for non-scoped e.g:
https://registry.npmjs.org/-/package/chalk/dist-tags
and other endpoints seem to be working for scoped packages e.g:
https://registry.npmjs.org/-/package/@freddyheppell%2Frandom-prime/collaborators
I think this is probably an issue with the upstream API. Does anyone have a rough idea when this started failing?

(edited by caleb to update link used for version badges)

Seeing same issue here: https://img.shields.io/npm/v/@locus-labs/mol-desktop-zoom-control?color=%231EA7FD&label=npm%20version&style=for-the-badge/@latest

Same problem:
https://img.shields.io/npm/v/@ptkdev/webcomponent-instagram-widget.svg

All - the fact that the issue is occurring on the npm registry API means that it's going to impact every package. Please refrain from the "my package too" types of comments.

Interestingly enough the registry.npm.taobao.org mirror endpoint appears to be working :thinking:

https://registry.npm.taobao.org/-/package/@freddyheppell%2Frandom-prime/dist-tags

Wonder if it's related in any way to https://github.com/npm/cli/issues/1431

Thanks for fixing my original post @calebcartwright

This seems to be more than a transient issue.

NPM can be a bit of a tricky project to report issues on sometimes because many their projects don't have issue trackers anymore and their forum is archived. Fortunately (for given values of "fortunately"), this issue affects the CLI as well so I've raised https://github.com/npm/cli/issues/1439 reporting this on the CLI repo (which does have a public issue tracker). We'll see where that goes.. If you're affected by this bug, track that issue and give it a :+1:

Thanks for digging into this.

I sent a tweet to the product manager for npm: https://twitter.com/paulmelnikow/status/1273316128610230279?s=20

The badge has started working again but nothing official from npm/cli#1439 yet

We believe this to be fixed - please let me know if you're still having problems.

This seems to be sorted so going to go ahead and close. Thank you for the report @freddyheppell and the quick fix @ethomson!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

korenyoni picture korenyoni  路  3Comments

lukeeey picture lukeeey  路  3Comments

paulmelnikow picture paulmelnikow  路  3Comments

techtonik picture techtonik  路  3Comments

chadwhitacre picture chadwhitacre  路  4Comments