🤖 Generated by the Codex Daily AI Engineer
Problem
The merge-queue production heal added for #2026 only runs when needs.deploy-prod.result == 'failure'. Cancelling a merge-group workflow after its deploy composite has started yields cancelled, so the heal job is cancelled/skipped even though workload push may already have moved the mutable latest artifact to an unmerged synthetic ref.
Live evidence: Platform merge-group run 29263580947 was cancelled after its 🚀 Deploy to Prod job had been in progress. The PR had already been dequeued, but 🩹 Heal Prod (restore main on merge-group failure) concluded cancelled with zero steps. There is therefore no proof that main was restored, and the current #2620 merge-group deploy must be allowed to finish naturally to heal or supersede the speculative artifact.
Expected behavior
Any merge-group run that may have entered the deployment composite but does not complete successfully must restore the current tip of main before the production lane is considered clean. Operator cancellation must not bypass that safety invariant.
Proposed direction
- Make the heal path cover cancelled deployments as well as failed deployments.
- Preserve the shared
prod-deploy concurrency lock and current-main checkout.
- Add a structural/behavioral workflow regression test for both
failure and cancelled results.
- Document the safe operator sequence for a stuck merge-group deploy so cancellation cannot strand a speculative artifact.
Acceptance criteria
Rough size
Small-to-medium: workflow condition hardening, regression coverage, and operator guidance.
Related: #2026.
Problem
The merge-queue production heal added for #2026 only runs when
needs.deploy-prod.result == 'failure'. Cancelling a merge-group workflow after its deploy composite has started yieldscancelled, so the heal job is cancelled/skipped even thoughworkload pushmay already have moved the mutablelatestartifact to an unmerged synthetic ref.Live evidence: Platform merge-group run 29263580947 was cancelled after its
🚀 Deploy to Prodjob had been in progress. The PR had already been dequeued, but🩹 Heal Prod (restore main on merge-group failure)concludedcancelledwith zero steps. There is therefore no proof that main was restored, and the current #2620 merge-group deploy must be allowed to finish naturally to heal or supersede the speculative artifact.Expected behavior
Any merge-group run that may have entered the deployment composite but does not complete successfully must restore the current tip of
mainbefore the production lane is considered clean. Operator cancellation must not bypass that safety invariant.Proposed direction
prod-deployconcurrency lock and current-main checkout.failureandcancelledresults.Acceptance criteria
Rough size
Small-to-medium: workflow condition hardening, regression coverage, and operator guidance.
Related: #2026.