Repository navigation
π release: tag the built commit instead of deferring when v5 advances - #17083
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Open PR overlap checkBase branch: Conflicts are checked with every PR merged onto the current tip of
|
Tagged Release deferred whenever v5's tip had moved past the commit docker.yml built, expecting the successor run to release. With merges landing faster than a multi-arch build no run ever saw an unmoved tip, every successor deferred again, and the hourly backstop applied the same tip-only test β v5 went from v5.186.4 (2026-10-18) to ~1,700 untagged commits. - precheck: release the built SHA when it is an ancestor of v5's tip and newer than the last v5.* tag; defer only when it is off-branch or a release already landed after it (version collision). - push_v5: the version tag names the release commit (built SHA + changelog), never the merge commit; 409 base-moved is retried, head-moved and a CONFLICTING PR hard-fail; the post-merge docker dispatch passes release_version only when the merge adds nothing but the changelog. - backstop: pick the newest successfully built ancestor of the tip instead of requiring the tip itself. - docker.yml: push builds get a per-run concurrency group β GitHub's queue holds one pending run per group and cancels the rest, which is what was killing most v5 builds. - test-release-push-retry.sh covers the new state machine; releases.md and the RACES/BACKSTOP headers describe the new rule; TRUSTED_SCRIPTS_TREE re-pinned. Signed-off-by: Andrew Anderson <andy@clubanderson.com>
cd9b8b8 to
acc633e
Compare
acc633e
βΉοΈ Sentinel notice β informational; author is trusted (owner), merge is not blockedHive flagged this PR (author @clubanderson, head
Hive did not add the |
|
Thank you for your contribution! Your PR has been merged. We'd love to hear how your experience was: share feedback |
β¦7128) A `${{ github.repository }}` mention in a bash comment inside the push_line step made GitHub evaluate the whole script as an expression; after the #17083 growth it passed the 21000-character limit, so every event since bde4411 has reported 'Invalid workflow file β¦ Exceeded max expression length 21000' for tagged-release.yml and no release has been considered on v5 or v6. Reword the comment; the script's value comes from $GITHUB_REPOSITORY already. Signed-off-by: Andrew Anderson <andy@clubanderson.com>
Problem
v5.186.4(2026-10-18) is still the newest tag after ~1,700 commits. #17015 removed therelease: nonedeadlock, but the next layer stalled too: Tagged Release'sprecheckdeferred wheneverv5's tip had moved past the commitdocker.ymlbuilt ("v5 is already at β¦"). With merges landing every few minutes and a multi-arch build taking ~15β40 min, no run ever saw an unmoved tip, every successor deferred again, and the hourly backstop applied the same tip-only test ("standing down: no successful publishing run for v5 tip"). Meanwhile GitHub's concurrency queue (one pending run per group) was cancelling mostdocker.ymlpush builds outright (runs 42400016149, 42401056583, 42403292505), so tip images were rarely published at all.Fix
tagged-release.ymlprecheck: release the built SHA when (a) it is an ancestor ofv5's tip and (b) the newestv5.*tag is an ancestor of it (no release landed after it; derived version does not already exist). Only (a)/(b) failing defers now, with::warning::.push_v5: the version tag names the release commit (built SHA + compiled changelog) β never the merge commit, so the tag's tree is exactly what the retagged images were built from. The release reachesv5by fast-forward push when the tip is unmoved, otherwise as a merge-commit PR. 409 "Base branch was modified" is retried within the existing deadline; 409 "Head branch was modified" hard-fails; a CONFLICTING PR (mergeable_state=dirty) hard-fails at once. The post-mergedocker.ymldispatch passesrelease_versiononly when the merge adds nothing but the changelog (otherwisegit describeβv5.x.y-N-gSHA, which is accurate).decide): picks the newest successfully built ancestor of the tip within the last 100 commits (vars.RELEASE_BACKSTOP_WINDOW), instead of requiring the tip itself.docker.yml: push builds get a per-run concurrency group (never cancelled, never queued behind each other); PR builds keep per-PR cancel-in-progress. Out-of-order completion is already handled bypublish-image-tags.sh's run-number generation guard.Invariants kept: never tag a commit whose images weren't published (tag = release commit parented on the built SHA;
Tag immutable version imagesstill retags<sha>digests); never tag twice (existing-tag refusal + the new last-tag ancestry check + thetagged-release-v5concurrency group).Tests / docs
src/scripts/test-release-push-retry.sh: base-moved is retried and still lands with the tag on the release commit; base-moved past the deadline hard-fails; head-moved hard-fails; conflicting PR hard-fails; moved-tip path skips the direct push, releases, omitsrelease_version. All cases pass locally;actionlintclean on both workflows.src/docs/releases.mdbackstop/tag-target/VERSIONsections updated.TRUSTED_SCRIPTS_TREEre-pinned.changelog.d/fixed-release-tag-built-ancestor.md.