Repository navigation
ci: the default profile follows Cortex, the Claude verdict decides the merge - #244
Conversation
…e merge The template takes Cortex's resolve and close-issues jobs and its merge aggregate, and loses its review job (review, repair, auto-merge arming). The resolver merges a head whose Pipeline succeeded and whose latest Claude verdict, bound to a review run of that head, approves (Cortex ADR-1121); low-risk Dependabot updates need no review (ADR-1126); the review's completion wakes the resolver (ADR-1127). claude-review.yml and its budget script are Cortex's (ADR-1119). The native profile is unchanged. pytest tests/: 3994 passed (3975 before). tools/ci_post_merge.py: 99 % lines. Co-Authored-By: Claude Fable 5.2 <[email protected]> Claude-Session: https://claude.ai/code/session_018kyZYsWnKSjpX4oNV19PCF Signed-off-by: Claude <[email protected]>
Co-Authored-By: Claude Fable 5.2 <[email protected]> Claude-Session: https://claude.ai/code/session_018kyZYsWnKSjpX4oNV19PCF Signed-off-by: Claude <[email protected]>
Codex Review Summary: ✅ CompletedThis 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: ea22459ce4
ℹ️ 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".
| f"{prefix}/actions/workflows/claude-review.yml/runs?head_sha={head}", | ||
| "workflow_runs", |
There was a problem hiding this comment.
Install the review workflow with the default CI profile
For repositories using the default render-ci profile, this new mandatory gate depends on a workflow that the renderer does not install. I checked prepare_files() and its output for an empty target: it delivers only the three Pipeline workflows and ci.json; claude-review.yml and its supporting assets remain exclusive to native_review=True. A repository upgrading from the previous default profile therefore loses its embedded review job without receiving a replacement, and every ordinary PR is held here even when all tests pass (the workflow lookup returns 404 when it does not exist). Include the compatible review workflow, budget script, and review assets in default-profile delivery before requiring its verdict.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Verified: prepare_files() delivered only the three Pipeline workflows and ci.json for the default profile, so a rendered consumer would have been held by merge held: no Claude review ran on this head. Fixed in the next commit: templates/ci/review/ carries claude-review.yml, scripts/ci_review_budget.py, the /review-pr command and its five reviewers, and the default profile delivers them (tests/test_ci_renderer.py::test_default_profile_delivers_the_review_its_resolver_waits_for, byte parity with this repository's own files).
Generated by Claude Code
A consumer rendered with the default profile received the resolver that holds every merge without a Claude verdict, but not claude-review.yml, its budget script, the /review-pr command or its reviewers (Codex P1 on #244). templates/ci/review carries them and prepare_files delivers them. pytest tests/: 3996 passed. Co-Authored-By: Claude Fable 5.2 <[email protected]> Claude-Session: https://claude.ai/code/session_018kyZYsWnKSjpX4oNV19PCF Signed-off-by: Claude <[email protected]>
… file Its Dependabot updates touch requirements-dev.in and requirements-dev.txt; without them in LOW_RISK_FILES every such update waits for a review that Dependabot runs never get. Co-Authored-By: Claude Fable 5.2 <[email protected]> Claude-Session: https://claude.ai/code/session_018kyZYsWnKSjpX4oNV19PCF Signed-off-by: Claude <[email protected]>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 56a48db3aa
ℹ️ 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".
| ref: main | ||
| fetch-depth: 1 | ||
| persist-credentials: false |
There was a problem hiding this comment.
Preserve fetch authentication in the default review assets
For a private repository using the default renderer, this checkout removes credentials before the pinned Claude action fetches the PR head. That action performs its fetch before installing its own Git authentication, so the review fails with an anonymous-fetch error and the new mandatory verdict gate prevents ordinary PRs from merging. This exact failure is already documented and tested in tests/test_ci_native_private_fetch.py, and the native review workflow supplies an Authorize pinned action fetch step to prevent it. Include the same authentication bridge in the newly delivered default workflow.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
The delivered workflow is Cortex's, byte for byte, and every repository that receives it is public, where the action's initial fetch needs no credential (reviews ran this way on ai-architect-mcp-spec#187 and ai-architect-mcp-codebase#489). A private consumer would need the fetch authorization step; that belongs in Cortex first, then here. Left open for the owner's decision.
Generated by Claude Code
| if _is_low_risk(pr, repository, api): | ||
| print("post-merge: low-risk dependency update, no review required") | ||
| else: | ||
| _review_approves(pr["number"], head, repository, api) |
There was a problem hiding this comment.
Provide a review path for higher-risk Dependabot updates
A Dependabot major-version update or GitHub Actions update cannot satisfy this new gate: _is_low_risk() rejects it, but both review jobs in the shipped claude-review.yml exclude every event whose actor is dependabot[bot]. Consequently, even a green Pipeline has no review run or verdict that can authorize the merge. The repository's own .github/dependabot.yml declares GitHub Actions updates, so this affects a configured update flow, not just hypothetical consumers. Provide a supported review trigger for these updates rather than requiring a verdict the automatic workflow cannot produce.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Intended: the tier comes from the change (Cortex ADR-1126). A major update or a change under .github/ stays on the reviewed path, and a Dependabot-triggered run receives no Claude secret, so such a pull request waits for a person: the owner merges it, or pushes to the branch, which runs the review. Workflow files always get a human. Left open for the owner if a bot review path is wanted for them.
Generated by Claude Code
| on: | ||
| workflow_run: | ||
| workflows: [Pipeline] | ||
| workflows: [Pipeline, PR Review] |
There was a problem hiding this comment.
Restrict review completion events to compatible resolver profiles
With render-ci --native-review, the renderer also installs this shared caller, but its completion engine still comes from templates/ci/native/pipeline.yml. That resolver accepts only a source named Pipeline at .github/workflows/pipeline.yml; it does not implement the new review-to-Pipeline lookup. Every successful native PR Review completion therefore starts a completion workflow that fails with source workflow differs and skips its downstream test chain. Executing the rendered native resolver with a successful review event reproduces this failure. Keep the native caller subscribed only to Pipeline completions, or teach its resolver to handle review completions.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Verified: the native resolver's _validate_run requires a source named Pipeline, so a PR Review completion would fail there with source workflow differs. Fixed in the next commit: caller_events() renders workflows: [Pipeline] for --native-review and keeps [Pipeline, PR Review] for the default profile (tests/test_ci_renderer.py::test_native_caller_wakes_on_the_pipeline_only).
Generated by Claude Code
The shared completion caller now listens to PR Review too, but the native resolver accepts a Pipeline source only, so each native review completion would have started a failing run (Codex P2 on #244). The renderer keeps the review wake-up for the default profile alone. Co-Authored-By: Claude Fable 5.2 <[email protected]> Claude-Session: https://claude.ai/code/session_018kyZYsWnKSjpX4oNV19PCF Signed-off-by: Claude <[email protected]>
CodeQL py/import-and-import-from (alert 258) on the file taken from Cortex; the same change is in cdeust/Cortex#963. Co-Authored-By: Claude Fable 5.2 <[email protected]> Claude-Session: https://claude.ai/code/session_018kyZYsWnKSjpX4oNV19PCF Signed-off-by: Claude <[email protected]>
Cortex #963: a per-PR concurrency group on claude-review.yml, so overlapping pushes cannot pass the three-review cap. Same file in templates/ci/review, which the default render delivers. Co-Authored-By: Claude Fable 5.2 <[email protected]> Claude-Session: https://claude.ai/code/session_018kyZYsWnKSjpX4oNV19PCF Signed-off-by: Claude <[email protected]>
Summary
The default CI profile follows Cortex, the source of truth for the CI of the eight repositories (owner direction 2026-11-09), and this repository gets the Claude reviews Cortex has.
templates/ci/pipeline.yml: Cortex'sresolveandclose-issuesjobs and itsmergeaggregate; thereviewjob (review, repair, auto-merge arming) is removed.tools/ci_post_merge.pyis the same resolver, byte for byte.claude-review.ymlrun of that head, approves (Cortex ADR-1121). A Dependabot minor or patch update of dependency manifests or locks outside.github/, in one GitHub-signed commit, needs no review (ADR-1126). The review's completion wakes the resolver as the Pipeline's does (ADR-1127)..github/workflows/claude-review.ymlandscripts/ci_review_budget.pyare Cortex's: three automatic reviews per pull request, each ending withVerdict: approveorVerdict: block(ADR-1119).scripts/lib/render_ci.py: default job order withoutreview, withclose-issues; the native profile keeps its own order; the completion caller may holdissues: write.What it supersedes
For the default profile: the review that "never blocks" (2026-10-29) and the
mergejob arming GitHub auto-merge (2026-11-03), which merged on green tests before any verdict. The Pipeline no longer repairs a red head itself;claude.yml(@claude) remains.Measured
python3 -m pytest tests/ -q: 3994 passed (3975 before). The tests of the deleted review job are removed; six Cortex test files are added.tools/ci_post_merge.py: 99 % line coverage (222 statements, 2 missed).bash tests/run-all.sh --group regression: 37 suites pass (the redaction suite needs a UTF-8 locale);--group e2e: 6 pass.tools/doc-count-check.sh,tools/doc-command-check.sh,tools/zetetic-checker.sh --staged(strict): pass.Known gaps
tools/craftsmanship-checker.sh --staged: 7 errors, all in code taken from Cortex byte for byte (parameter count, nesting). To be fixed in Cortex first, then replicated.Claude review budgetfails on this pull request only: the job checks outmain, wherescripts/ci_review_budget.pydoes not exist yet. It is not a required check.main's.Record:
tasks/ci-cortex-parity-20261110.md.Generated by Claude Code