Skip to content

gate: replay a route only on boxes that start where it starts - #52

Merged
TusanHomichi merged 3 commits into
mainfrom
claude/project-thread-qturuz
Oct 13, 2026
Merged

TusanHomichi merged 3 commits into
mainfrom
claude/project-thread-qturuz

Conversation

@TusanHomichi

@TusanHomichi TusanHomichi commented Oct 13, 2026 •

Copy link
Copy Markdown
Member

Requested by Peter · project thread

Before: CI replayed every route of a family on every box of that family. The new el/centos7-lamp box (#51) got the CentOS 5 route, whose first hop (to centos6) rolled back as soon as CentOS 6's tooling hit EL7's glibc. The box PR went red for something no box starting at CentOS 7 can do.

After: a route is replayed only on its family's boxes that start at the route's from, and those are the decoys. To keep that from leaving anything unreplayed, the gate now refuses three things:

  • a route no box starts at
  • a fires_on claim on a box that no route pinning the fix starts at
  • an existing box that changes its release

How

  • check.starts(box, route): same family, and box.release == route.from. tools/affected.py (all four change kinds) and wend verify --all both use it.
  • check.pairing_errors, run in check.py's main:
    • every route needs a family box at its from
    • every fires_on box must exist and start where some route pinning the fix starts (a fix no route pins is skipped)
    • three new broken cases in test_check.py
  • affected.py exits non-zero when an existing box changes its release; that's a new box. A brand-new box with no route yet is allowed, because AGENTS step 2 lands boxes before their routes. It gets built and replayed in its route's PR.
  • gate.yml plan assigns the matrix before echoing it, so a refusal fails plan. Before, a failing $(...) inside echo left it green with an empty matrix.
  • wend verify --base prints affected.py's reason instead of a traceback.
  • Docs: CONTRIBUTING (what gets replayed, decoys), SPEC (Decoys), AGENTS steps 5 and 6, plus the wend and affected.py docstrings.
  • The Rust client has no box-level checks today, so pairing_errors lives only in the Python gate, as check_box does. parity.py reports identical (137 checker cases).

Evidence

  • tools/check.py ok and tools/test_check.py 0 wrong, with the new cases refusing as intended and the real atlas passing.
  • Every existing route/box pair already starts at the same release, so coverage of today's routes doesn't change.
  • Simulations against main:
    • add box: el/centos7-lamp #51's box commit gives an empty matrix, and check.py stays ok.
    • Moving el/centos5-web to release = "centos6" makes affected.py exit 1: "changes its release from centos5 to centos6; add a new box instead".
  • An independent Claude review over three rounds signed off on 027da11.
  • What this PR's own CI does and doesn't check: its plan and schema jobs run main's affected.py and check.py, and it touches only tools, docs and the workflow. Its matrix is therefore empty, and the new rules take effect on PRs after it merges.

🤖 Generated with Claude Code

https://claude.ai/code/session_01U79sdXK2gVuGi4U9ty7qHc

affected.py paired every route of a family with every box of that
family. A box that starts at another release can't walk the route:
CI replayed the CentOS 5 route on a new CentOS 7 box, whose first hop
(to centos6) can only roll back. Pair a route with the family's boxes
whose release is the route's from. Every existing route/box pair
already starts at the same release, so no coverage changes today.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01U79sdXK2gVuGi4U9ty7qHc
Signed-off-by: Claude <[email protected]>
@TusanHomichi TusanHomichi self-assigned this Oct 13, 2026
@github-actions github-actions Bot added the needs-claude-review Waiting on the Claude review layer label Oct 13, 2026
Review of the pairing change: with replays only where a route starts,
a route whose from has no box, a fires_on claim on a box no pinning
route starts at, or an existing box moved to another release would
leave CI nothing to replay or check.

- check.py: starts() (shared by affected.py and wend verify --all) and
  pairing_errors(): every route needs a box at its from; every
  fires_on box must exist and start where a route pinning the fix
  starts. Three new broken cases in test_check.py.
- affected.py: an existing box may not change its release.
- wend verify --all uses the same pairing; docstrings and AGENTS
  step 5 say so.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01U79sdXK2gVuGi4U9ty7qHc
Signed-off-by: Claude <[email protected]>
A refusal inside $(...) in an echo left plan green with an empty
matrix. Assign first so bash -e stops the step. wend verify --base
prints affected.py's reason instead of a traceback.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01U79sdXK2gVuGi4U9ty7qHc
Signed-off-by: Claude <[email protected]>

Copy link
Copy Markdown
Member Author

Independent Claude review: sign-off on 027da11, after three rounds.

  • Round 1: the start-release pairing could leave changes with zero replays. That covered a new route at a release no box has, an edited from, a box moved to another release, and fires_on claims that can't be checked. wend verify --all and some docs still paired every box. All fixed in 93572d5.
  • Round 2: the plan step swallowed affected.py's exit code inside echo "$(...)", and wend verify --base hid the reason behind a traceback. Both fixed in 027da11.
  • Accepted, not fixed: renaming a box that no fix claims is the same as deleting it. That was already possible, and box files get human review.

I'll merge once client and the rest are green on this head.


Generated by Claude Code

@TusanHomichi
TusanHomichi marked this pull request as ready for review October 13, 2026 04:57
@TusanHomichi
TusanHomichi merged commit 4fc18de into main Oct 13, 2026
7 checks passed
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 13, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-13T04:59:06.834273Z 027da11 Draft marked ready
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@TusanHomichi
TusanHomichi deleted the claude/project-thread-qturuz branch October 13, 2026 04:58
This was referenced Oct 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-claude-review Waiting on the Claude review layer

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants