docs: source download badges from pepy.tech to stop pypistats rate-limit errors#250
Merged
Conversation
…mit errors The six monthly-download badges fetched from img.shields.io/pypi/dm/<pkg>, which shields sources from pypistats.org. pypistats rate-limits by IP and fails on ~6 concurrent uncached requests, so the README's six badges routinely rendered "rate limited by upstream service". Switch each download badge to static.pepy.tech/badge/<pkg>/month (pepy serves statically cached SVGs from a different upstream) and repoint the click-through to pepy.tech/projects/<pkg>. Metric stays monthly downloads; pyversions badges are unchanged. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The six monthly-download badges in the README used
img.shields.io/pypi/dm/<pkg>, which shields.io sources from pypistats.org. pypistats rate-limits by IP and fails when ~6 uncached badge requests arrive at once — the shields maintainers describe this exact case (badges/shields#11620, psf/pypistats.org#100). With exactly six download badges, the README routinely rendered "rate limited by upstream service".Change
Swap each download badge to pepy.tech, which serves statically cached SVGs from a different upstream:
img.shields.io/pypi/dm/<pkg>.svg→static.pepy.tech/badge/<pkg>/monthpypistats.org/packages/<pkg>→pepy.tech/projects/<pkg>Metric stays monthly downloads (
downloads/month). Thepyversionsbadges are untouched (they don't hit pypistats).Verification
static.pepy.tech/badge/<pkg>/monthendpoints return HTTP 200 and render a count (e.g.downloads/month | 16k).grepconfirms zeropypi/dmreferences remain and 6 pepy badges present.🤖 Generated with Claude Code