Repository navigation
fix(ci): roll back prepare-release when a phase job is cancelled - #1089
Merged
Merged
Conversation
The rollback guard only matches result == 'failure' for prepare, extension and open-pr, so a run cancelled after the freeze commit strands the partial release branch and the freeze commit on dev. Pin the cancelled-handling in the job-shape assertions (both caller copies) before extending the guard. Refs: #1078
Extend the rollback guard so needs.<job>.result == 'cancelled' for prepare, extension and open-pr triggers the rollback alongside 'failure'. The guard already used always(), which is what keeps the job eligible to run after the run itself is cancelled; without the cancelled match a run cancelled after the freeze commit stranded the partial release/X.Y.Z branch and the freeze commit on dev. Applied to both the devkit workflow and the independently authored scaffold copy (not manifest-synced), which shares the guard shape. Refs: #1078
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements #1078 (review follow-up from #1068).
The rollback job's guard now matches
cancelledfor each phase (prepare/extension/open-pr) alongsidefailure, so cancelling a run after the freeze commit lands rolls back the partial release branch and dev freeze exactly like a failure.always()is kept (and documented as load-bearing — it's what keeps the job eligible after a run-level cancel);validate.result == 'success'is kept deliberately (a cancelled validate means no freeze commit exists to roll back).Scope note: the scaffolded twin (
assets/workspace/.github/workflows/prepare-release.yml) is independently authored (not manifest-synced, per #996/#991) and had the identical gap — both copies fixed, and the shape tests are parametrized over both.TDD: RED (2 pytest + 1 bats failures) → GREEN (
test_workflow_prepare_extension.py15 passed, bats rollback filter 3 ok); fulljust precommitgreen (actionlint). Runtime path exercises at the next prepare-release run. Changelog under## [1.2.0] - TBD### Fixed, root + mirror.Refs: #1078