Repository navigation
fix(cicd): run the status-bridge ordering guard in the same pod as the POST (#1029) - #1030
Merged
Merged
Conversation
…f1018aa9 Fr-Commit: bookkeeping
…f75fed955127 Fr-Commit: bookkeeping
… f6d2f9bfade0 Fr-Commit: bookkeeping
…e POST (#1029) The current-state guard and the forward POST were separate tasks, so the read->POST gap included the forward pod's start. On 2026-11-22 (derio-net/runs-fr PR #52) that took 74s: the guard read Gitea while pending was genuinely current, the terminal status posted in the gap, and the stale pending posted last, stranding the GitHub check and firing layer-25-delivery-overdue. - New StepAction github-status-report holds the POST, moved verbatim from the github-status Task plus an optional guard-file (true = skip, anything else posts: fail-open). - github-status Task now refs it with no guard; its script is byte-identical, so CI status posts are unchanged. - stoa-status-bridge is one task: step `check` writes $(results.superseded.path), step `report` reads it. Steps start back-to-back in one pod. - Tests: single-pod shape, guard behaviour against the real script, Task delegation; existing script tests retargeted to the StepAction. - tekton gotcha prose + one-liner updated. Closes #1029 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…c5a128ec68 Fr-Commit: bookkeeping
…0a2c0b2b6 Fr-Commit: bookkeeping
…ted script tests (#1029) test_ci_status_always_reported built the Task path from the task name, so the literal-path sweep missed it. Its loader now executes the StepAction script a ref: step points at. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- plan: repair widen-fr-version-ceiling (11 files) Migrated automatically at fr CLI entry: the installed fr changed under artifacts written for an older one (artifact migration framework, spec 2026-08-30 §3.C/§3.D). Only the rewritten artifact paths are in this commit; unrelated working-tree and staged changes were left alone. Fr-Commit: migrate
…62f52d0fd0 Fr-Commit: bookkeeping
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.
Closes #1029
Root cause
stoa-status-bridge's ordering guard was check-then-act across two TaskRuns.current-stateread Gitea, and thenforward(a separate pod) POSTed to GitHub. So the gap between the read and the write included a whole pod start.On 2026-11-22 (derio-net/runs-fr PR #52,
acceptance-report / pages (push)):vwtxcqzshdThe guard's answer was correct at the moment it asked. The POST then happened 74s later. The stale pending posted last, so it won (a commit status is never revisited), and
layer-25-delivery-overduefired.docs/runbooks/frank-gotchas/tekton.mdhad already named this residual window, but didn't account for the pod start inside it.Fix
github-status-report(apps/tekton/tasks/github-status-report.yaml). The POST moved here verbatim from thegithub-statusTask, plus an optionalguard-file:trueskips the POST, and anything else posts (fail-open).github-statusTaskrefs the StepAction and passes no guard. I checked programmatically that the script, image, command, securityContext, env, params and computeResources are byte-identical to before, so the 4 CI pipelines' status posts are unchanged.stoa-status-bridgeis now one task,forward, with two steps.checkwrites$(results.superseded.path), andreport(the StepAction) reads/tekton/results/superseded. Steps of one TaskRun start back-to-back in one pod, so there is no pod schedule between reading Gitea and writing GitHub.Failing test first
test_stoa_status_bridge.py::test_check_and_post_run_in_one_pod: one task, steps[check, report], and the same result file on both sides.test_github_status_report_guard.py: runs the StepAction's real script with curl stubbed.true→ no POST.false, empty, missing file, or no guard → POST. A third test checks that the Task forwards every param and no guard.token_select,quota_422,ci_delivery_check) now point at the StepAction.Verification
kubectl apply --dry-run=server --validate=stricton Tekton v1.6.0 accepted the StepAction, the Task, and the Pipeline (an inlinetaskSpecwith aref:step).main.Post-merge test plan
status.operationState.operation.sync.revisionontekton-extrasequals the merge SHA, andkubectl -n tekton-pipelines get stepaction github-status-reportexists.github-statusTaskRun shows Succeeded, and its status lands on GitHub.stoa-status-bridgerun shows Succeeded with stepscheck+report, and the status lands on GitHub.pending is stale … not postingin thereportstep log.ci-delivery-checklogs stay free ofstatus delivery mismatch.The incident status was already repaired via
scripts/ci_status_backfill.py(stoa-status-bridge-nc9nv).🤖 Generated with Claude Code