Claim new flyteplugins PyPI names at merge time, not release time - #1538
Merged
Conversation
PyPI limits each account to creating 4 new projects per 24h (pypi/support#10572), which broke the v2.7.0 release for the new flyteplugins-github and flyteplugins-llamacpp packages (429), and an unpublished name is squattable by anyone -- four flyteplugins names were lost exactly that way and are now quarantined. Add a claim-plugin-names workflow that: - fails a PR early (with the rate-limit rationale) when it adds more than 4 new flyteplugins distributions, so it gets split before merge; - publishes a 0.0.0a0 claim wheel for every still-unregistered name as soon as a plugin lands on main; - drains any backlog at 4/day on a daily schedule (e.g. names PyPI frees from quarantine later). Release runs of publish.yml then only ever upload to existing projects and never hit the new-project creation limit. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01NwQixBcyR5va6BC75jaQx3
cosmicBboy
marked this pull request as ready for review
September 4, 2026 18:57
cosmicBboy
enabled auto-merge (squash)
September 4, 2026 19:15
SVilgelm
approved these changes
Sep 4, 2026
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.
Why
PyPI limits each account to creating 4 new projects per 24 hours (pypi/support#10572). Uploads to existing projects are unlimited — the limit only bites on the first-ever publish of a name. This broke the v2.7.0 release (run):
flyteplugins-githubandflyteplugins-llamacppwere new names and got429 Too Many Requestsafter earlier new names in the same run consumed the budget.Separately, a
flyteplugins-*name that sits declared in the tree but unpublished is squattable by anyone —flyteplugins-redis,-echo,-nsight, and-agento11ywere lost exactly that way and are now quarantined on PyPI (PEP 541 requests pending).What
New
claim-plugin-names.ymlworkflow:pull_request(touchingplugins/**/pyproject.toml): fails early if a single PR adds more than 4 newflyteplugins-*distributions, telling the author to split the PR and why (the PyPI new-project rate limit).pushtomain: immediately publishes a0.0.0a0claim wheel for every still-unregistered name, so the PyPI project is registered the day the plugin merges instead of at the next release. If more than 4 names are somehow unregistered on a push (PR check bypassed), it fails loudly before publishing anything.schedule/workflow_dispatch: drains any backlog at 4/day (e.g. names PyPI later frees from quarantine become 404 and get claimed automatically).0.0.0a0is a pre-release, so defaultpipresolution never picks the claim wheel over a real release.Also adds a cross-reference comment in
publish.yml'sdiscover-plugin-packagesjob: by release time every discovered name should already exist, so releases only upload to existing projects and never hit the creation limit.Validation
Dry-ran both scripts against the live repo/PyPI:
flyteplugins-github,flyteplugins-llamacpp); the 4 quarantined names correctly read as already-registered (HTTP 200) and are skippedFirst run of this workflow will claim
flyteplugins-githubandflyteplugins-llamacpp(2 ≤ 4 budget).Notes for reviewers
check-pr-plugin-countjob a required status check onmainso oversized plugin PRs can't merge.github.repository == 'flyteorg/flyte-sdk'and uses the samePYPI_USERNAME/PYPI_PASSWORDsecrets aspublish.yml.🤖 Generated with Claude Code
https://claude.ai/code/session_01NwQixBcyR5va6BC75jaQx3