Skip to content

.github: make the post-release action kind-aware - #2596

Merged
sespiros merged 2 commits into
mainfrom
sse/release-kind-input
Aug 24, 2026
Merged

.github: make the post-release action kind-aware#2596
sespiros merged 2 commits into
mainfrom
sse/release-kind-input

Conversation

@sespiros

Copy link
Copy Markdown
Collaborator

Follow-up to #2594.

That PR added a third boolean to prepare_post_release_pr, alongside create_docs_release and bump_version, all three wired to the same inputs.kind == 'minor' at the call site.
The action was asking its caller three questions that have only ever had one answer between them, so it takes kind once and decides internally.
Across roughly 30 post-release PRs since 1.5.2 those booleans have only ever been all-on or all-off (the 4-commit and 2-commit PRs), never mixed.
No behaviour change for minors, and release_promote.yml still relies on the default.

The second commit restores the guard the hot-fix had to drop.
Skipping the version check on a patch left checkout_main_ref unvalidated on that path, which is the mistake the check exists to catch.
Main can never carry a patch version but is always ahead of one, so a patch asserts that ordering instead of an exact match.
By construction this is weaker than the minor check: it catches a ref that is behind the release, not one that is ahead and still wrong.

Should land after #2594.
Main-only, no backport needed.

@sespiros
sespiros requested a review from charludo August 20, 2026 18:12
@sespiros sespiros added no changelog PRs not listed in the release notes do not merge This shouldn't be merged at this point labels Aug 20, 2026
Three separate boolean inputs all wired to the same `kind == 'minor'`
expression at the call site meant a fourth minor-only step would have
been easy to add and forget. Take `kind` once and decide inside the
action instead. No behaviour change: release_promote is always a minor
and keeps relying on the default.

Signed-off-by: Spyros Seimenis <sse@edgeless.systems>
Skipping the check entirely on a patch left that path with no guard
against a wrong checkout_main_ref, which is the failure it exists to
catch. main can't carry the patch version, but it is always ahead of it,
so assert that ordering instead. sort -V rather than a string compare,
so 1.23.10 and 1.30.0 don't misorder.

Signed-off-by: Spyros Seimenis <sse@edgeless.systems>
@sespiros
sespiros force-pushed the sse/release-kind-input branch from 466b571 to 4deb1eb Compare August 20, 2026 18:17
@sespiros sespiros removed the do not merge This shouldn't be merged at this point label Aug 20, 2026

@charludo charludo left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes!! Thank you.

@sespiros
sespiros merged commit fca78ed into main Aug 24, 2026
14 of 15 checks passed
@sespiros
sespiros deleted the sse/release-kind-input branch August 24, 2026 08:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no changelog PRs not listed in the release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants