Commit 3fe7bd2
authored
Add release-tag consistency guards to CI and release workflows (#250)
* Add release-tag consistency guards to CI and release workflows
Close the gap that let main claim v0.14.0 as the latest release for a
day before the tag existed (README's @v0.14.0 Action pin 404'd for
anyone copying it; ROADMAP said "Latest release: v0.14.0" while PyPI
was at 0.13.0).
Public surfaces already move in lockstep with pyproject.toml
(tests/test_public_surface_contract.py), but nothing checked the
lockstep claim against release reality. Two guards:
- ci.yml release-tag-consistency job (pushes to main only, never PRs):
the tag v{pyproject version} must exist on origin, so a merged
version bump without a pushed tag turns main red with the exact
command to cut the release.
- release.yml fail-fast step: the pushed tag must equal
v{pyproject version} before the test/build/publish pipeline runs —
PyPI uploads are immutable, so this is the last cheap moment to
catch a mistagged release.
ROADMAP's latest-release line now links to the GitHub /releases/latest
page (no version in the URL, so nothing new to bump) and names the CI
job that enforces it. Phrasing is unchanged so the existing
VERSION_LITERAL_TARGETS pin in test_public_surface_contract.py still
matches.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
* release-tag-consistency: document the retest path and tag-only scope
Review finding on #250: the failure text told maintainers to push the
missing tag, but a tag push triggers release.yml — it does not retest
the failed main run, which stays red until re-run or the next main
push. Name the working recovery explicitly ("Re-run failed jobs"
re-checks origin's live tag list) in both the error output and the job
comment, and explain why a tag trigger on this workflow would not help
(new run on the tag ref, badge stays red, duplicates the full test job
release.yml already runs on tags).
Also make the guard's tag-only scope explicit: the tag triggers
release.yml, the canonical publisher, which fails loudly if the PyPI
upload or GitHub Release step breaks — so tag-exists plus a green
release run covers /releases/latest and PyPI. Querying PyPI here would
add an external dependency that lags publish by minutes and can
false-fail right after a legitimate release.1 parent 7b6150c commit 3fe7bd2
3 files changed
Lines changed: 77 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
86 | 86 | | |
87 | 87 | | |
88 | 88 | | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
22 | 36 | | |
23 | 37 | | |
24 | 38 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
6 | 10 | | |
7 | 11 | | |
8 | 12 | | |
| |||
0 commit comments