Repository navigation
Description
Refreshed plan (2026-10-17, unblocking review)
This section supersedes any text below that conflicts with it.
Decisions
- Decision D12 (owner, 2026-10-17): "fix(release): the cut opens as a pull request only after the release pull request's checks pass, so a fix for a failing check reaches the version's changelog #1544 gates the cut on every check run and status on the head except names in a new advisory list in .github/roadmap.toml, plus a required check that fails on an uncut ready release PR." This item delivers that required check. fix(release): the cut opens as a pull request only after the release pull request's checks pass, so a fix for a failing check reaches the version's changelog #1544 keeps the cut gate and the advisory list.
- Decision D16 (owner, 2026-10-17): "v0.2.38 may go over the cap of 16 for now; unblocking work goes first." This item stays in v0.2.38 because fix(release): the cut opens as a pull request only after the release pull request's checks pass, so a fix for a failing check reaches the version's changelog #1544 waits on it.
- Part 1 only. The Pages build and the Argo CD render move to a new backlog item (part 2, drafted for intake), because fix(release): the cut opens as a pull request only after the release pull request's checks pass, so a fix for a failing check reaches the version's changelog #1544 needs only the release-job rehearsal.
- The Service-image criteria are dropped.
ci.yml's Service Image job already builds, smoke-tests and scans the image of every pull request into main, release pull requests included, without pushing (refactor(release): the release no longer pins, bumps or pre-publishes the service image tag; image updater rolls service:latest #1486). refactor(release): the release no longer pins, bumps or pre-publishes the service image tag; image updater rolls service:latest #1486 also removed the publication plan and the pin that the 2026-10-09 update relied on. - The rehearsal gets its own workflow. It is not release.yml on
pull_requestand not aci.ymljob.ci.ymldeliberately leaves outready_for_review, and release.yml's release job holds write scopes, so no write-scoped job shares a trigger with pull requests. - Its token is read-only:
contents: read,issues: read,pull-requests: read, nothing else, withpersist-credentials: false. It runs onpull_requestonly, neverpull_request_target. The two extra read scopes cover the pull request, label, milestone and issue reads; neither grants a write. - It reads the label, milestone, draft state and open issues live through the API, not from the event payload. A re-run reuses the original payload, so a payload read would never see a fix.
- Each verification step exists once, in a composite action that the release job and the rehearsal both call. This replaces the 2026-10-09 design of release.yml on
pull_requestwith its writing steps gated off. apply_cutmoves here from fix(release): the cut opens as a pull request only after the release pull request's checks pass, so a fix for a failing check reaches the version's changelog #1544 (its design step 2 and two of its criteria), because the rehearsal needs it first. fix(release): the cut opens as a pull request only after the release pull request's checks pass, so a fix for a failing check reaches the version's changelog #1544 keeps the Service flow.- The check-readiness criterion from the 2026-10-08 comment stays. RELEASE_CYCLE.md already names fix(release): a release pull request rehearses the cut and the release job read-only, so a green pull request means the release job passes on merge #1425 for it, and it covers a fix admitted after the check last ran.
Scope
- Workflow
.github/workflows/release-rehearsal.ymlwith one job,Release Rehearsal.- It runs on
pull_requestinto main with types opened, synchronize, reopened, ready_for_review, converted_to_draft, labeled, unlabeled, milestoned and demilestoned. actionlint 1.7.12 accepts all of them. - Its
iflimits it to headsrelease/v*. On any other pull request the job is skipped, which GitHub reports as success, so requiring the check blocks no other pull request.
- It runs on
- A
devops releasesubcommand holds the logic (for exampledevops release rehearse <pr>):- It reads the pull request (same repository, head
release/vX.Y.Z, thereleaselabel, milestonevX.Y.Z), tagvX.Y.Zand every open issue in the milestone. - It reads the head's cut state from the checkout:
pyproject.tomlholds X.Y.Z,CHANGELOG.mdholds a non-empty[X.Y.Z]section, andchangelog.d/holds nothing but README.md. - A ready pull request with an uncut head fails (D12).
- A draft with an uncut head gets
apply_cut(root, version, today)applied to its checkout, with the version taken from the branch name. - The composite action then runs
devops release check --allow-dirty --skip-ci,uv buildwith SHA256SUMS, notes extraction (which must not be empty) anddevops devcontainer validate.
- It reads the pull request (same repository, head
apply_cutdoes the bump, the collection and the fragment deletion. It replaces cut_release's prepare block and_execute_release_prepare.devops pr check-readinessrefuses a pull request intorelease/vX.Y.Zonce that release's pull request has merged.- Moved elsewhere:
- the Pages build and the deploy render go to the part 2 item (backlog);
- the Service image is already covered by
ci.yml(refactor(release): the release no longer pins, bumps or pre-publishes the service image tag; image updater rolls service:latest #1486); - the cut-after-green flow, the advisory list and returning the PR to draft stay in fix(release): the cut opens as a pull request only after the release pull request's checks pass, so a fix for a failing check reaches the version's changelog #1544.
Delivery
- One PR, size M, "Closes fix(release): a release pull request rehearses the cut and the release job read-only, so a green pull request means the release job passes on merge #1425". Tests come first.
Acceptance criteria (these replace the three checklists below)
- A release pull request whose milestone holds an open issue fails the check, naming each open issue. With every issue closed, the check passes. Pull requests in the milestone, the release pull request among them, are not counted.
- A missing
releaselabel, a missing milestonevX.Y.Z, or an existing tagvX.Y.Zfails the check, naming which. Setting the missing label or milestone re-runs the check, which then passes with no new push. - Any failed GitHub read fails the check with the reason: the pull request, every page of the milestone's issues (not only the first 100), and the tag. Only a 404 on
git/ref/tags/vX.Y.Zmeans the tag is absent. The milestone read does not reuse_fetch_raw_milestone_issue_numbers, which turns a failed read into an empty set. - A ready release pull request whose head is uncut fails, naming each reason: the version in
pyproject.toml, a missing or empty section, or a fragment left inchangelog.d/. The same branch, once cut, passes. feat(release): v0.2.30 #1473's case (no 0.2.30 section) is a regression test. - On a draft with an uncut head, the cut is applied before the checks. A fragment with a line outside a category (like
changelog.d/419.mdat 2f3ed2a) fails the check, naming the file and line, and so does a misnamed fragment. The same branch with the fragment fixed passes. -
apply_cutis the only code that bumps and collects. The rehearsal,devops release prepareandcut_releaseproduce byte-identical files for the same tree and date. - The verification steps exist once, in a composite action that both jobs call. Empty notes after the fallback fail both jobs. release.yml's triggers, its
if, and its writing steps (tag, GitHub Release, milestone close, image pushes, attestation) are unchanged and never run onpull_request. - A test over the workflow file asserts that the rehearsal grants only
contents: read,issues: readandpull-requests: read, checks out withpersist-credentials: false, uses no secret but the job token, runs onpull_requestonly, and is skipped for heads outsiderelease/v*. -
devops pr check-readinessrefuses a pull request intorelease/vX.Y.Zwhose release pull request has merged. It names the merged release pull request and tells the author to retarget to the next release's branch. A failed read of the release pull request refuses too, naming the error. The rule is one more entry in_GROUNDING_CHECKS. - The logic lives in
devopscommands tested offline, with gh faked at the process edge and each test under 1 s. - actionlint and
uv run devops cipass. RELEASE_CYCLE.md §6-7 name the check, and achangelog.d/1425.mdfragment exists. - Pending a person: the main ruleset requires
Release Rehearsal, so a red or uncut ready release pull request cannot merge.
Current references (main 3dd7fa6)
.github/workflows/release.yml:3-13: the triggers (push to main, tags, dispatch)..github/workflows/release.yml:32-36: the write scopes..github/workflows/release.yml:86-103: the check, the build, and notes extraction with its fallback..github/workflows/release.yml:105-142: tag, GitHub Release and milestone close..github/workflows/release.yml:144-145: devcontainer validate..github/workflows/ci.yml:7-10: the pull request types, which leave outready_for_review..github/workflows/ci.yml:203-209: the Service Image job on every pull request into main.src/devops_cli/release/cut.py:1068-1083: the cut's bump and collection.src/devops_cli/commands/release.py:171-189: the prepare path's bump and collection.src/devops_cli/release/cut.py:782-798: the milestone read that swallows failures.src/devops_cli/commands/pr.py:1462-1469:_is_release_pr.src/devops_cli/commands/pr.py:1657:_closes_an_item_of_its_release.src/devops_cli/commands/pr.py:1691-1698:_GROUNDING_CHECKS.RELEASE_CYCLE.md:199-210: Step 3, the release pull request's checks.RELEASE_CYCLE.md:217: the hand edit of the section after the cut.RELEASE_CYCLE.md:218: names fix(release): a release pull request rehearses the cut and the release job read-only, so a green pull request means the release job passes on merge #1425 for this check and for the readiness refusal.
Dependencies and order
- Nothing blocks this item. It is in v0.2.38.
- Two other changes edit
cut_releasenear the same lines. feat(release): a release is cut only after every argo cd application builds at the release head and its live changes are shown #1343's PR 1 (issue open, P1, v0.2.37; no PR yet) adds the Argo CD gate betweencut.py:1065and:1066. The cut-as-pull-request item (drafted, not filed, planned for v0.2.38) splitscut_releasein two. Neither change blocks this item and this item blocks neither. Whichever lands later rebases, and once this item lands, every cut path callsapply_cut. - It unblocks fix(release): the cut opens as a pull request only after the release pull request's checks pass, so a fix for a failing check reaches the version's changelog #1544 (open,
status/blocked, no milestone, planned for v0.2.39 after this item and the cut-as-pull-request item). - Until fix(release): the cut opens as a pull request only after the release pull request's checks pass, so a fix for a failing check reaches the version's changelog #1544 lands, a fragment merged into a cut release branch makes a ready release pull request fail this check. A person then re-cuts by hand (as in chore(release): cut v0.2.36 — version 0.2.36, the changelog fragments collected and the roadmap rendered #1614), or the fix edits the version's section, as RELEASE_CYCLE.md:217 says.
Problem
A critical fix admitted to a cut release (#1294) can still be open when someone merges the release pull request. release.yml then closes the milestone on publish, and no job moves an item out of a shipped release (reprioritize.py: "the job moves no item out of a shipped release"). So the fix sits in a closed milestone that no job plans again. #1362 closes only items that a merged pull request delivered, so an undelivered fix stays open there.
devops pr check-readiness exempts release pull requests from grounding (pr.py) and runs in no workflow, so nothing stops this merge. RELEASE_CYCLE.md §7 (since #1294) tells a person to merge the release pull request only once its milestone has no open item, but nothing enforces it.
Proposed remedy
A required ci.yml status check on release/* → main pull requests. It reads the release's milestone and fails while any issue in it is open, naming each one. It also fails when the read fails, so a GitHub error never passes the check.
Acceptance criteria
- A release pull request whose milestone holds an open issue gets a failing check naming that issue; with every issue closed, the check passes.
- A failed milestone read fails the check with the reason.
- The check's logic lives in a
devopscommand tested offline, with gh faked at the process edge, each test under 1 s. - RELEASE_CYCLE.md §7 names the check;
uv run devops cipasses.
Found while delivering #1294. Related: #1294, #1362, #1020, #1414.
Update 2026-10-09: owner requirement — a green PR into main means the release succeeds
Owner, 2026-10-09: "the checks on a pull request targeting main, should tell me if a merge is going to succeed" and "if something fails during the release workflow, it should have also failed on the pull request checks for the branch targeting main."
What happened: the Service cut v0.2.30 and opened #1473 with green checks; it merged, and Release Orchestration failed on main (run 37887128320) at devops release check: CHANGELOG.md's newest section was 0.2.29 while pyproject.toml was 0.2.30. Release Orchestration runs only on push to main, tags and dispatch, so none of its steps ran on the PR. Recovery took a second PR into main (#1474).
This item's check is therefore widened to that requirement. Simplest form, so the PR and the merge can't drift: Release Orchestration's release job also runs on pull_request into main, and every step that tags, publishes, closes the milestone or pushes an image is skipped on that event. So the PR runs the same steps the merge runs: devops release check, notes extraction (non-empty), uv build, devops devcontainer validate, and a check that tag vX.Y.Z does not exist yet. Add the checks the merge relies on that no step makes today:
- the release PR carries the
releaselabel and milestonevX.Y.Z(whatrelease_statereads; the v0.2.29 start was missed without it); - the Service image
service:vX.Y.Zthatk8s/devops/kustomization.yamlpins exists in GHCR (fix(release): the Service image a release pins is published before main pins it, so Argo CD never rolls the roadmap Service onto a missing image #1451 publishes it from the release branch); - the release's milestone holds no open item (this item's original criterion).
Acceptance criteria to add:
- A release PR whose branch lacks the CHANGELOG section, lacks the label or milestone, pins a missing image, or whose milestone holds an open item, fails its PR check with a message naming what is missing; the same branch fixed passes.
- The job's publishing steps run only on push to main, tags and dispatch, and the workflow has one copy of each verification step.
- Person step: the main ruleset requires this check, so a red release PR cannot merge.
Update 2026-10-09 (later): every release and distribution step is rehearsed read-only on the release PR
Owner, 2026-10-09: "It is standard practice to do read-only validation of all release steps in a release pr, and that is what I expect to happen for all workflows around release and distribution." This widens the update above from Release Orchestration to every workflow that releases or distributes on a merge to main.
Inventory at main (8598e79), what each does after the merge, and what a PR into main runs today:
| Path | After the merge | On a release PR today |
|---|---|---|
release.yml job release |
devops release check, uv build + SHA256SUMS, notes extraction, tag vX.Y.Z, GitHub Release, milestone close, devops devcontainer validate, devcontainer image vX.Y.Z + latest |
nothing (push, tags and dispatch only) |
release.yml job service-image |
the publication plan (reuse the image the release branch published when its inputs label matches, else build), build, push, attest | nothing; ci.yml's service-image build skips release PRs (!startsWith(github.head_ref, 'release/v')) |
| GitHub Pages | legacy build of main:/docs (Jekyll) |
nothing |
| Argo CD | syncs the deploy overlay, which pins service:vX.Y.Z |
nothing checks the render or that the pinned image exists |
ci.yml job devcontainer |
— | builds (and publishes a PR-tagged) devcontainer image: already rehearsed |
Required (one PR; the same steps on both events, so the rehearsal and the release can't drift):
-
release.ymlalso runs onpull_requestinto main. Every step runs on the PR except those that write: the tag push, the GitHub Release, the milestone close, image pushes and the attestation. Those are gated on push, tags and dispatch. On the PR, the release job also fails when tagvX.Y.Zalready exists, the PR lacks thereleaselabel or milestonevX.Y.Z, or the milestone holds an open item. - The
service-imagejob runs its publication plan on the PR read-only: it fails when the image the overlay pins doesn't exist with matching inputs and would need a build it can't make, and it builds without pushing whenever the plan would build. - A docs-site job builds
docs/with GitHub's Pages Jekyll build on the PR (no deploy), so a site build failure fails the PR. - A deploy-render job runs
kustomize buildon the Argo CD overlay and checks every image it pins exists in its registry. - Release PR feat(release): v0.2.30 #1473's case is a regression test: a branch without the version's CHANGELOG section fails the PR check that the merge would have failed.
- Person step: the main ruleset requires these checks, so a red release PR cannot merge.
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsDone
Activity
dan-petty-bot commentedon Oct 8, 2026
Intake placed this item to the backlog: at intake only a critical fix goes into a release; a release start pulls Ready items in, P0 features first.
It prevents a real operational failure (items permanently stuck in a closed milestone) but requires a specific sequence of events and can be worked around manually by reopening the milestone.It closes a gap that silently drops work from the planning pipeline, but only in the narrow case where an undelivered fix is still open at release-PR merge time.Requires a new devops command with offline tests faking gh, a ci.yml workflow entry, RELEASE_CYCLE.md documentation, and acceptance-criteria verification.dan-petty commentedon Oct 8, 2026
Scope addition from the review of #1294:
devops pr check-readinessshould also refuse a pull request intorelease/vX.Y.Zonce that release's pull request has merged. Today_closes_an_item_of_its_release(commands/pr.py, around lines 1612-1641) compares only the closed issue's milestone. A fix still open when the release PR merges can therefore merge into the dead release branch, and #1362's closure then closes it as delivered from that shipped branch, although its change never reachesmain.Acceptance criterion to add: a PR into a release branch whose release PR has merged fails readiness, naming the merged release PR and telling the author to retarget it to the next release's branch. Test it offline with gh faked at the process edge.
dan-petty commentedon Oct 9, 2026
Finding: v0.2.29 Service gap assessment (2026-10-09)
The v0.2.29 release PR (#1455) was opened by hand with the
releaselabel but no milestone.release_statefinds release PRs only throughmilestone(number){pullRequests(labels:[release])}, so the Service read v0.2.29 as started, not shipped, and its first round after the ship (21:52:56Z, 4 min after the GitHub Release) started nothing. That round still stamped reprioritize, so the ship was older than the cutoff and nothing retried; v0.2.30 started only after a person set the milestone and ran reprioritize (00:16Z).Proposed criterion for this check (no new mechanism): it also fails when the release PR lacks milestone
vX.Y.Zor thereleaselabel, and names which one is missing. Until then, open release PRs only withdevops release pr, which passes--milestone vX.Y.Z.[-]fix(release): a release pull request's check fails while its release's milestone holds an open item[/-][+]fix(release): a release pull request rehearses every release and distribution step read-only, so a green PR means the merge publishes[/+]dan-petty commentedon Oct 9, 2026
Note (2026-10-09): the Service image is moving to Argo CD Image Updater on
service:latestby digest (#1485 in v0.2.31; #1486 in v0.2.32 removes the release-branch publication plan, the pin and its check). Once #1486 lands, this item's Service-image criterion is simply "ci.yml builds, smoke-tests and scans the release PR's image without pushing", and the overlay image-existence check skips the Image Updater-managedservice:latest. The other criteria stand.[-]fix(release): a release pull request rehearses every release and distribution step read-only, so a green PR means the merge publishes[/-][+]fix(release): a release pull request rehearses the cut and the release job read-only, so a green pull request means the release job passes on merge[/+]dan-petty commentedon Oct 22, 2026
Superseded by ADR 0012 (docs/adr/0012-releases-are-derived-by-release-please-from-trunk-and-milestones-are-planning-buckets.md). The cut, the fragments or the hand-built release pull request that this issue concerns are deleted by the new release model.