Repository navigation
Description
Description
devkit's own promote-release.yml checks the release PR's draft status and
approvals only in the merge job, which runs after promote has already
moved GHCR :latest and published the draft GitHub Release. A release PR that is
draft, unapproved, or CI-red therefore fails the promote after its two
irreversible-ish effects have landed, leaving the release published but unmerged.
The scaffolded consumer template does not have this shape: it performs the same
Find and verify release PR check in validate (fail-fast, before promote)
and repeats it in merge. Only the upstream workflow is missing the early gate.
validate |
promote |
merge |
|
|---|---|---|---|
.github/workflows/promote-release.yml (devkit) |
version/arch, GHCR images, cosign, draft release, downstream gate — no PR check | moves :latest, publishes the release |
first PR draft/approval/CI check (:405-465) |
assets/workspace/.github/workflows/promote-release.yml (consumers) |
PR draft/approval/CI check (:181-222) |
same | repeats the check (:394-433) |
Steps to Reproduce
- Have a release PR for
X.Y.Zthat is not approved (or is still draft). - Dispatch
promote-release.ymlwithversion=X.Y.Z. validatepasses — it never looks at the PR.promotemoves:latestand runsgh release edit "$VERSION" --draft=false.mergefails:ERROR: PR #N does not have approvals.
Expected Behavior
The promote refuses before publishing anything, the way the consumer template
does — the approval gate is checked in validate.
Actual Behavior
The run fails at merge with :latest already moved and the GitHub Release
already published, so the repository is left in a half-promoted state: the
release exists publicly, main does not contain the release commit, and the
release PR is still open. Recovery is to obtain the approval and re-run the
failed job — but the published release cannot be walked back, since published
releases are immutable org-wide and deleting one tombstones its tag name.
Has this fired?
No — it is latent. Every promote run to date has succeeded
(31604989709 1.8.0, 31248884977, 30913559426, 30585083552,
30207909845, 30021617295). The reason is operator discipline: the maintainer
re-approves the release PR before dispatching promote.
That is precisely why this is worth fixing now rather than filing and forgetting.
#1474 established that a final
release.yml run's finalize job always pushes to the release branch and so
always dismisses the approval where stale-review dismissal is enabled — org-wide
in vig-os. The trigger condition for this defect is therefore the default
state of every final release, and until #1486 documented the re-approval step,
the only thing standing between it and a half-promoted release was an undocumented
habit.
Possible Solution
Mirror the consumer template rather than inventing a new shape: lift the
Find and verify release PR check into validate and keep the copy in
merge (state can change between the two jobs — the consumer template keeps both
deliberately). That also removes an upstream/template divergence in a workflow
pair that is otherwise kept in step.
Note the merge copy resolves PR_NUMBER as a step output consumed further down,
so the lift is a duplication of the check, not a move of the whole step.
Environment
devkit 1.8.0 / dev @4ec1c803, .github/workflows/promote-release.yml
(validate :39, promote :299, merge :380).
Changelog Category
Fixed
Activity
test(release): pin the release-PR gate in promote validate
fix(release): verify the release PR in promote validate, before publi…
fix(release): verify the release PR in promote validate, before publi…
c-vigo commentedon Aug 13, 2026
Fixed on
devvia #1490 (merge commit7c252876).The gate now runs in
validate, beforepromotemoves:latestor publishes the Release; themergecopy stays, since PR state can change between the two jobs. Mirroring the consumer template wholesale also brought the mergeability gate (#1132 — BEHIND/BLOCKED/DIRTY), which the upstream workflow had never carried in either job.tests/test_promote_release.pyis now parametrized over both copies rather than pinning the scaffold alone — the divergence was invisible precisely because the shape suite only ever looked at the template. All four[devkit]cases were RED before the fix.Closing manually — a
Closesline in a PR targetingdevdoes not auto-close (GitHub only honours it on the default branch).chore: release 1.9.0 (#1498)
feat(release): collect the single human approval at promote, not befo…
feat(release): single human approval at promote; unattended smoke leg (…
chore: release 1.10.0 (#1515)