Skip to content

fix(ci): pypi-publish skip-existing=true so re-pushed tags don't go red#238

Merged
WaylandYang merged 1 commit into
mainfrom
fix/pypi-skip-existing
Jun 11, 2026
Merged

fix(ci): pypi-publish skip-existing=true so re-pushed tags don't go red#238
WaylandYang merged 1 commit into
mainfrom
fix/pypi-skip-existing

Conversation

@WaylandYang

Copy link
Copy Markdown
Contributor

Why

publish-pypi.yml currently fails with HTTP 400 `File already exists` whenever a v* tag gets force-pushed (which I did earlier today to fix release.yml's Docker job for v0.5.2 — see #235). The publish step has logically nothing to do (PyPI versions are immutable, so a re-push is a no-op), but the action defaults to `skip-existing: false`, so the no-op shows up as a red X on the publish-pypi workflow.

What

Set `skip-existing: true` on the `pypa/gh-action-pypi-publish` step. PyPI's immutability guarantee means we never overwrite an existing version anyway; this just turns "no-op publish" from a failure into a green skip.

Test plan

🤖 Generated with Claude Code

publish-pypi.yml was failing with HTTP 400 'File already exists' when a
v* tag got force-pushed (e.g. when fixing release.yml's Docker job for
v0.5.2 — see #235). The publish step has nothing to do, but the action
defaults to skip-existing=false, so the no-op surfaces as a failure.

Set skip-existing=true: PyPI immutability means re-publish is a logical
no-op anyway, and treating it as a hard error means every tag-fix dance
leaves a red X behind that's actually a non-event.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@WaylandYang WaylandYang merged commit ef69d04 into main Jun 11, 2026
2 checks passed
@WaylandYang WaylandYang deleted the fix/pypi-skip-existing branch June 11, 2026 01:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant