Skip to content

ci: move the contract cells and the judging of their markers into test.yml (migration M5b) - #281

Merged
aRustyDev merged 4 commits into
mainfrom
ci/test-cells
Nov 17, 2026
Merged

aRustyDev merged 4 commits into
mainfrom
ci/test-cells

Conversation

@aRustyDev

@aRustyDev aRustyDev commented Nov 17, 2026 •

Copy link
Copy Markdown
Owner

What

M5b of Phase 1 of the CI split (plan, phase,
ADR-0102): the second half of M5, the stage you asked me to split. The job
contract (a matrix call of contract-cell.yml) moves from ci.yml into test.yml, and the rule that judges its cells moves with it: from gate to
test's own verdict job. After this, ci.yml holds only changes, the calls and gate, which is the migration's acceptance for that file (a test now
pins it). Commits: the plan documents (M5a recorded as done, M5b planned in detail), the build, a change to the baseline script that the build made necessary, and a merge of main.

No new action. As you decided, the verdict action is extended with two optional inputs, cell-job (default empty: none) and cells (default []); the
four other callers pass neither and are unchanged. When cell-job is set, a first step downloads the cell-ok-* markers (the step gate ran, at the same pin, with
the same continue-on-error) and the judge is given CELL_JOB, PLANNED and REPORTED_DIR.

What changes in the repository

  • test.yml: two new inputs, matrix and cells (strings holding JSON; required when called, with defaults when run alone); the job contract, moved from
    ci.yml between pg-adapter and mutants, as it was; and the verdict job now needs five jobs and passes cell-job: contract and cells: ${{ inputs.cells }}.
    The cell calls are now three levels deep (ci.yml to test.yml to contract-cell.yml), against a limit of ten. contract-cell.yml itself is unchanged
    but for one comment, and so are its other callers.
  • .github/actions/verdict/action.yml: the two inputs, the conditional download, and the three variables taken from them.
  • ci.yml: contract is gone; the test call passes the planner's matrix and cells; gate needs [changes, test, lint, web, documentation, security],
    downloads no marker, and is given no PLANNED and no REPORTED_DIR.
  • assert-gate.sh: its defaults describe the top-level gate, which has no cells now: the default cell job is none (it was contract), and the default
    known jobs are the five called workflows.
  • The planner's map holds test: (ci-scripts, hermetic, pg-adapter, contract, mutants). top is now only workflows.

The cost of the design, said plainly

Until now a verdict job that forgot CELL_JOB failed, because the default asked for cells it was not given (test-ci-scripts.sh had a case for it). With the
default being none, a callee that forgets it passes without judging cells. I did not hide that case: it is now callee: a verdict job that forgot CELL_JOB judges no cells and passes, with a comment saying why. The property moved to the places that can hold it: the wiring test requires the one workflow that holds contract to pass
cell-job: contract and cells
(and every other workflow to pass neither), and the mutants show it can fail: the call forgetting cell-job, forgetting cells, passing other
cells, or naming another job as the cell job, are each killed by it.

The gate's cell cases moved, they were not dropped

The cells' cases (a planned cell that never reports, a marker for an unplanned cell, no cell planned, no marker, cells planned with the cell job not expected, the unset PLANNED
and REPORTED_DIR) and the per-job loop's special case for contract are now run at the level of a verdict job whose cell job is contract, with the same texts and the same
exit statuses. The gate-level section lost its special case and gained one the other direction: a gate that judges no cells must not read a PLANNED it is given. The script
goes from 162 to 196 cases.

Proof that it is the same

  1. Parity, mechanically (scripts/ci-commands.py). Real output:

    changed  verdict/action.yml:action:verdict  (expected)
    changed  ci.yml:test  (expected)
    changed  ci.yml:gate  (expected)
    changed  test.yml:verdict  (expected)
    changed  test.yml:contract  (expected)
    53 jobs before, 53 after: 48 unchanged, 0 moved, 5 changed, 0 appeared, 0 gone; PARITY
    

    Read the five diffs: contract differs only in where its matrix comes from (fromJSON(needs.changes.outputs.matrix) becomes fromJSON(inputs.matrix); its
    fail-fast, its call, its with and its permissions are identical); the test call gains the two inputs; test / verdict gains cell-job, cells and contract in
    its list. And the job moved by a script that refused unless every line it removed (all but the three that differ by design) was found, in order, in test.yml.

  2. Locally, the ci-scripts commands under dash (37, compared with test.yml's mechanically) and the guards of deps: all pass (the gate's cases 196, the wiring test 136
    checks, the planner's 7,008). actionlint is clean, with its control.

  3. The mutant driver: 226 hand mutants, each killed; the 9 that change nothing survive (27 more than ci: move the four plain jobs of the test concern into test.yml, the fifth called workflow (migration M5a) #275's 199). I read the first failing check of each of the 27 new ones, and of the
    ones whose text I re-aimed: each fails a check on its own fault.

  4. The run (44175085217, on f5f2ca7, a full run because the change edits ci.yml): 42 of 42 jobs succeeded, and assert-required-contexts.sh (strict on gate)
    certified that the one required context reported and is green. The cells are now test / contract (native-memory, main) / native-memory main, three levels deep, as planned.
    The markers did cross the nested call: test / verdict's collection step found the run's artifacts, filtered them to cell-ok-*, and its judge said
    ok: 5 expected jobs passed, the rest were skipped; 26 of 26 planned cells reported success. gate said ok: 5 expected jobs passed, the rest were skipped,
    with no cell in it. On the runner: the gate's 196 cases, the planner's 7,008 checks, the wiring test's 136 and mutants=226 killed=226 survived=0 broken=0 equivalent-wrong=0.

  5. Two probes, each a draft PR closed unmerged (branches deleted), each passing the wiring test, the lint and actionlint locally first:

    • probe: one planned cell never uploads its marker (do not merge) #282, a planned cell never uploads its marker (the cell native-memory sweeper runs and succeeds; only the upload step is skipped). Failed: test / verdict
      and gate, and nothing else (40 of 42 succeeded). test / verdict: GATE FAIL: planned cells that never reported success: native-memory sweeper, after
      Found 52 artifact(s) (53 in the passing run). gate: test was expected to run and its result is 'failure'. This is the rule that moved, working on the new level.
    • probe: the call of the verdict action skipped in test.yml (do not merge) #283, the call of the verdict action skipped in test.yml. Failed: gate alone (41 of 42 succeeded: every cell and every job of test.yml, test / verdict
      among them, and the calling job test reported success). gate: test succeeded but its verdict output is 'missing', not 'pass': it calls a workflow, and one whose verdict job did not run proves nothing. This one matters more here than in the other callees: with the call skipped no cell is judged at all and every
      job is green, and only the output rule of gate refuses it.
  6. ci-baseline.py (third commit): a cell's check name changed, so the script's split on the first caller name would have counted the 26 cells' minutes as test's.
    A cell is now recognised by its own shape, with or without a caller in front, and stays of the group contract. Self-test 38 to 44 checks; with the pattern
    disabled exactly the two nested-cell checks fail. Run on the three runs of this PR and its probes, the real names group as 26 contract cells and the 5 jobs of test (a
    check of the names, not a baseline: those runs are this PR's own).

A fourth commit merges main (#280 and #284: the core test and the lockfile order; no CI file, no conflict), so the run after this body was written is on the current main.

What this does not show

  • The run above is on f5f2ca7. The commits after it touch only the baseline script (under .agents/plans/) and merge main. The run on the head is a full run again,
    because the PR as a whole edits ci.yml; I read it when it is over and say here if it differs from this one.
  • Comments: ci-commands.py does not compare them (the move script compared the contract job's, line by line).
  • The affected-only run of a change that edits a workflow, the nightly run and an rc/* run: the migration's acceptance, taken once after M6.
  • That a real failing cell is judged as well as a missing marker: probe probe: one planned cell never uploads its marker (do not merge) #282 withheld a marker from a cell that passed. A cell that fails stops at Run the cell, so
    contract is failure and the verdict's needs rule says so; that path is the gate's old per-job one, unchanged, and is covered by the callee level's per-job cases in
    test-ci-scripts.sh (the job loop), not by a probe.

Next: M6, e2e.yml (e2e-schedule.yml renamed), which is not a callee: the index and the planner's lists change. After it, the migration's acceptance: a full dispatch run, an
affected-only run, an rc/* run, the nightly, and the baseline measured again.

🤖 Generated with Claude Code

aRustyDev and others added 2 commits November 17, 2026 15:35
…ng of its cells)

M5a merged as #275: the parity, the wiring checks, the mutants, a full run and two probes are recorded in the phase document, with what the stage found (a semantic merge conflict, three re-anchored mutants) and one thing that was not its own: main's run on the merge commit went red from a new RustSec advisory (chrono), since handled by a temporary exception.

M5b is planned in detail: the nested matrix call, the verdict action extended with cell-job and cells (the owner's decision), the gate no longer judging cells and what that costs (a verdict job that forgets CELL_JOB no longer fails by default; the wiring test carries that property now), and the gate's cell cases moved to the callee level, not dropped.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
…t.yml (migration M5b)

The job contract (a matrix call of contract-cell.yml) moves from ci.yml into test.yml, moved with its call, strategy, permissions and comment unchanged but for where its matrix comes from (ci-commands.py; the move was checked line by line). test.yml takes the planner's matrix and cells as inputs, and the cell calls are now three levels deep. ci.yml now holds only changes, the calls and gate, which a test pins.

The rule that judges the cells moves with it, from gate to test's verdict job: the verdict action (extended, as the owner decided) gains the optional inputs cell-job and cells, downloads the cell-ok-* markers when given a cell job, and gives the judge CELL_JOB, PLANNED and REPORTED_DIR. gate downloads nothing and judges no cells; assert-gate.sh's default cell job becomes none. The cost: a verdict job that forgets CELL_JOB no longer fails by default, so the wiring test holds test.yml to pass cell-job and cells, and mutants show it can fail.

The gate's cell cases are re-run at the level of a verdict job whose cell job is contract, not dropped (162 to 196 cases). The planner's map, the indexes, cicd.md, running.md and the mutant driver follow: 226 mutants, all killed, 9 that change nothing survive.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
aRustyDev and others added 2 commits November 17, 2026 16:20
…ipt, wherever it is called from

Since M5b a cell's check is test / contract (<target>, <pass>) / <target> <pass>, not contract (...) / ..., so the script's split on the first caller name would have counted the 26 cells' minutes as test's. A cell is now recognised by its own shape, with or without a caller before it, and stays of the group contract. The self-test goes from 38 to 44 checks; with the pattern disabled exactly the two nested-cell checks fail. Run on the three runs of #281 and its probes, the real names group as 26 contract cells and the 5 jobs of test (that is a check of the names, not a baseline).

Refs: #281

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@aRustyDev

Copy link
Copy Markdown
Owner Author

The run on the head, 4c3c833 (44178951266), is a full run as expected and is green: 42 of 42 jobs succeeded, assert-required-contexts.sh (strict on gate) certified the one required context, and the PR is CLEAN and MERGEABLE. test / verdict: ok: 5 expected jobs passed, the rest were skipped; 26 of 26 planned cells reported success. gate: ok: 5 expected jobs passed, the rest were skipped. It does not differ from the run on f5f2ca7.

@aRustyDev
aRustyDev merged commit 5cadf2f into main Nov 17, 2026
46 checks passed
@aRustyDev
aRustyDev deleted the ci/test-cells branch November 17, 2026 21:42
aRustyDev added a commit that referenced this pull request Nov 18, 2026
* docs(plans): record M5b as done, and plan M6 (e2e.yml, the rename of e2e-schedule.yml)

M5b merged as #281: parity, the wiring checks, the mutants, two full runs and two probes are recorded in the phase document, with what the stage found (the cost of the default cell job, a cell's new check name, a Cargo.lock swept in by commit -a).

M6 is planned in detail: it is not a callee, so the callee stages' probes cannot show anything about it. Its two probes are the two stale references a rename can leave and the gate does see (the planner test's list, the index row). It is also the first stage whose own run is affected-only, because it does not edit ci.yml, and its pull request runs the renamed workflow through the paths filter.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>

* ci: rename e2e-schedule.yml to e2e.yml (migration M6)

The daily browser-journey workflow takes the name of its concern, as the plan's layout says: the file, name, the paths filter of its own pull-request trigger and the concurrency group change; the two jobs, their calls of contract-cell.yml, with and permissions do not (ci-commands.py: 2 moved, every one identical, with a control that reports a changed call). Four comments that the move of contract into test.yml made false are corrected in the same edit.

The name follows where it is used: the planner test's list of workflows that run no check, the workflows index, cicd.md, app-and-e2e.md and two pointers in the contrail plan. The planner needs no rule: e2e.yml falls under the generic .github/workflows/ rule exactly as the old file did. The dated records of runs under the old name stay as written.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>

* docs(plans): record main's run on M5b's merge commit

42 of 42 jobs succeeded, the first run of the nested cells on main.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>

---------

Co-authored-by: Claude Sonnet 5.5 <[email protected]>
aRustyDev added a commit that referenced this pull request Nov 18, 2026
Since M5b (#281) assert-gate.sh's default cell job is none, so a
verdict job that forgot its cell job judged no cells and passed; the
wiring test was the only thing that held test.yml to name it. The
verdict action passes `cells` through whatever `cell-job` says, so a
forgotten `cell-job` arrives here as a level with no cell job and a
non-empty PLANNED. That is now refused ("cells are planned but no cell
job is named"): only an unset PLANNED or an empty array is no cells.
The four workflows without cells are given the action's default `[]`
and ci.yml's gate none, so neither changes.

- test-ci-scripts.sh: the gate case that ignored a PLANNED it was given
  is replaced by five (two cells, an object, not JSON: refused; `[]`
  and `[ ]`: passed), and a verdict job that forgot CELL_JOB and is
  given cells is refused (201 cases, were 196).
- mutate_gate.py: three mutants of the rule (removed, compared by text,
  reading no PLANNED), each killed.
- PLAN.md: the Test phase's row records what #279 left for it: an
  ungated workflow that repeats test.yml's preview commands and is the
  only check of the provisioner's wasm32 build, and planner paths
  handled before RULES.

Co-authored-by: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant