Repository navigation
ci: gate tag releases on green main workflows - #4636
Conversation
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 15 minutes. View limit details
Walkthrough
Merge Risk:
|
Codex Review Summary: ❌ FailedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 68ecde1be3
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| run_json="$(gh api "repos/$GH_REPO/actions/workflows/$wid/runs?branch=$MAIN_BRANCH&event=push&head_sha=$SHA&per_page=100" \ | ||
| | jq -c --arg sha "$SHA" '[.workflow_runs[] | select(.head_sha == $sha)] | sort_by(.created_at) | last // empty')" | ||
| if [ -z "$run_json" ]; then | ||
| verdict_fail "$wf: no push-to-main run for $SHA (missing main-gate signal)" | ||
| failures=$((failures + 1)) |
There was a problem hiding this comment.
Trigger all watched main workflows before requiring their runs
For an otherwise-green main commit changing only pkgs/mcpx/**, this gate cannot pass: .github/workflows/id-check.yml:45–53 and .github/workflows/id-bench.yml:23–29 restrict push runs to id-related paths. Conversely, id-only changes do not trigger mcpx or mcpx conformance, whose push triggers also have path filters. Requiring every watched workflow's push run on the exact release SHA therefore blocks ordinary component releases indefinitely, even after all applicable checks succeed; manually dispatching the missing workflows cannot help because this query filters to event=push. Make all watched main workflows run on every main push, or otherwise arrange for the required runs before enforcing this gate.
AGENTS.md reference: AGENTS.md:L34-L34
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Disposition (task 14751, lane code-p): addressed in two parts. (1) The fallback you and CodeRabbit both flagged now applies ONLY to the watched workflows whose push trigger is path-filtered on current main — mcpx, mcpx conformance, id bench (PATH_FILTERED_WORKFLOWS in release-gate.sh, verified against the workflow files 2026-11-10); every other watched workflow requires an exact-SHA push run. (2) Remaining, named on the PR: five watched workflows (nix ci, mcpx nix build, go modules build, identity build, map build) have NO push trigger on current main at all (dispatch/schedule only), so no run semantics in this script can ever judge them by push runs — that watched-set semantics decision belongs to issue #1782 and is the one blocker left before merge. PR rebased to current main at e24db29; release-gate.sh --self-test passes (fallback fixtures moved to mcpx).
| needs: release-gate | ||
| # Keep dispatch snapshots runnable while requiring the gate for every | ||
| # tag-push path (including the GHCR container push below). | ||
| if: always() && (github.event_name == 'workflow_dispatch' || needs.release-gate.result == 'success') |
There was a problem hiding this comment.
Preserve downstream snapshot jobs when the gate is skipped
On workflow_dispatch, release-gate is skipped and artifacts explicitly overrides that with always(), but the downstream installer and container jobs only declare needs: artifacts and retain their implicit success conditions. GitHub documents that a “failure or skip applies to all jobs in the dependency chain,” so these snapshot jobs are skipped despite the successful artifact build. See GitHub's dependency semantics. Manual runs therefore lose both the installer exercise and container build/version verification that previously ran. Either let the gate complete successfully without checking on dispatch, or give both downstream jobs explicit status conditions that allow a skipped gate while still requiring successful artifacts.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Disposition (task 14751, lane code-p): fixed. installer and container in mcpx-release.yml now carry explicit conditions — after the CodeRabbit minor fix they read if: always() && needs.artifacts.result == 'success' — so a skipped release-gate no longer skips the dispatch snapshot chain, while a failed artifacts job still stops them. Same shape on the artifacts job itself for the gate (always() + dispatch-or-gate-success). Verified in the rebased head e24db29; both workflow files parse (yq) and the gate jobs wire into the current job graph.
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
state: parked Lane code-v claimed task 14751 (batch issue #7297, part 4) for PR #4636 and parks it resumable after fresh revalidation - this PR gates real tag releases, and the remaining work does not fit a safe verification window this shift: Fresh state (2026-11-10): PR #4636 OPEN, no hard-stop labels. The user/escalated on issue #1782 dates to 2026-11-03 (task 6538) and rests on the same revoked authorship premise ("authored by dezren39") plus then-unresolved CodeRabbit findings; CodeRabbit's current check on the PR PASSES, and the PR itself is unlabeled - so the escalation is stale, recorded here, but it does not finish the PR either: REMAINING before merge (exact resume steps):
The PR is NOT superseded: no release-gate exists on main today (no .github/scripts/release-gate.sh), and tag pushes to goreleaser still cut releases ungated. Task 14751 parks with this state; issue #1782 and PR #4636 stay open. |
3cd3b92 to
e24db29
Compare
|
Agent note — state: blocked (decision on #1782) · task 14751, lane code-p Progress this shift (resuming lane code-v's park steps):
THE ONE REMAINING BLOCKER (decision for issue #1782, kept user/escalated): five of the nine watched workflows — nix ci, mcpx nix build, go modules build, identity build, map build — have NO push trigger on current main (workflow_dispatch / schedule only, consistent with the #6185 dispatch-only posture). The gate queries event=push runs, so those five can never produce a verdict and the gate would refuse every release forever. Options: (a) drop the five from the gate's watched set — gate judges only push-running workflows; (b) judge the five by their latest completed run on main whose head_sha is the release SHA or its ancestor (dispatch/schedule runs count) — recommended: it preserves the 'judged code is in the release' property without new triggers; (c) add push triggers to the five — contradicts the dispatch-only policy. On the #1782 decision, the remaining work is: adjust release-gate.sh + ci-policy text for the chosen semantics, re-run --self-test, merge. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e24db2963e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| runs_json="$(gh api "repos/$GH_REPO/actions/workflows/$wid/runs?branch=$MAIN_BRANCH&event=push&per_page=100")" \ | ||
| || die "could not list runs for $wf" | ||
| run_json="$(jq -c --arg sha "$SHA" '[.workflow_runs[] | select(.head_sha == $sha)] | sort_by(.created_at) | last // empty' <<<"$runs_json")" |
There was a problem hiding this comment.
Enable push runs for the remaining required workflows
Tag releases remain blocked even after the path-filter fallback fix. The fresh evidence is that .github/workflows/nix-ci.yml:4–8 permits only schedule/dispatch runs, while mcpx-nixbuild.yml:20–21, go-modules-build.yml:31–32, identity-build.yml:14–15, and map-build.yml:14–15 permit only dispatch runs. All five are watched, excluded from the fallback list, and therefore required to have exact-SHA push runs that their triggers cannot produce. Successful manual or nightly runs cannot satisfy this query: the Actions API documentation specifies that event “Returns workflow run triggered by the event you specify.” Enable the required push-to-main triggers, or arrange equivalent exact-SHA verification that the gate accepts, before enforcing this requirement.
AGENTS.md reference: AGENTS.md:L34-L34
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Disposition (task 14751, lane code-d, 2026-11-14): addressed by decision (b), implemented on this PR's current head 9f49a83 — no push triggers were added; instead the gate no longer requires push runs from workflows that cannot produce them. release-gate.sh now classifies all nine watched workflows by verified trigger class: NON_PUSH_WORKFLOWS (nix ci — schedule/workflow_dispatch only) are judged by their latest completed run on main whose head SHA is the release SHA or an ancestor of it, and PATH_FILTERED_WORKFLOWS carries all seven path-filtered push workflows (mcpx, mcpx conformance, mcpx nix build, go modules build, identity build, map build, id bench) with latest-push-run fallback. Decision recorded on issue #1782 (comment 6850372902, option (b) with the trigger-audit correction). Verified this shift: bash .github/scripts/release-gate.sh --self-test — all pass, including the non-push and fallback fixtures.
P1: path-filtered workflows (id, id bench, mcpx, mcpx conformance) legitimately have no push run on SHAs outside their paths, so an exact-SHA-or-refuse rule would block every ordinary component release. Gate now prefers the exact-SHA run and falls back to the workflow's latest push-to-main run (main health), still refusing on missing/red/pending. Documents the path-filter-gap residual risk. P2: installer/container jobs gain the same always() opt-in as artifacts so a skipped push-only release-gate no longer drops the dispatch snapshot chain. Self-test extended with fallback / fallback-red fixtures (16/16 pass); shellcheck clean; live --audit run refuses the currently-red main.
…or-before the release SHA (task 14751) Decision on #1782 (option (b) of issue note 6782949534), recorded 2026-11-13: nix ci has no push trigger (schedule/dispatch only), so the push-only rule could never pass it and every tag release would be refused permanently. It is now judged by its latest completed run on main whose head SHA is the release SHA or an ancestor of it. Fresh trigger audit on current main also showed mcpx nix build, go modules build, identity build and map build are push path-filtered but were missing from PATH_FILTERED_WORKFLOWS; added (verified in their workflow files). Self-test: all pass, including real-git ancestor checks and full-gate non-push fixtures (ancestor green passes, ancestor red refuses, descendant refuses). ci-policy.md Release gate section re-inserted on the restructured doc with the three trigger classes.
e24db29 to
9f49a83
Compare
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
state: parked (CI wait) Resumed from lane code-p's implementation_complete checkpoint and finished the blocking decision:
Resume: read CI at head 9f49a83 fresh; disposition any new Codex findings on this head; merge under the standing criteria when green (checks green, diff = the 4 PR files only). If CI fails on the gate script, fix forward on this branch. |
|
🤖 Agent note · picked up
|
|
🤖 Agent note · done
|
Summary
Adds the shared gate to
.github/workflows/goreleaser.ymland.github/workflows/mcpx-release.yml. Manual dispatch remains a non-publishing snapshot path..github/ci-policy.mdrecords the fail-closed rule and the SHA-scoped, reviewed hotfix override procedure. Part of #1782.Evidence
.github/scripts/release-gate.sh --self-testpasses green, failed, missing, pending, and stale-SHA fixtures;bash -n, YAML parse withyq, andgit diff --checkpass.Merge Danger
Door: Two-way; the gate can be rolled back or adjusted in a reviewed change.
Blast Radius: Release publishing only. Tag releases wait for current-main head and all watched main-tier workflows to succeed; snapshots remain unchanged.
Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.Summary by CodeRabbit