Skip to content

ct-runner: only reports deselected rows; capability wins over selection (#286) - #287

Merged
lannbot merged 2 commits into
mainfrom
fix-286-deselected-rows
Sep 5, 2026
Merged

ct-runner: only reports deselected rows; capability wins over selection (#286)#287
lannbot merged 2 commits into
mainfrom
fix-286-deselected-rows

Conversation

@lannbot

@lannbot lannbot commented Sep 5, 2026

Copy link
Copy Markdown
Collaborator

Closes #286.

What

runSuite applied only before tag gating with a bare continue (run-suite.ts:270-272), so a filtered-out case vanished from the row stream — and so did a tags-excluded case that also fell outside the selection. The reference runner it mirrors (polymorph-test js/viewer/harness.mjs runCases; docs/runner-policy.md §"Selection is not capability") does the opposite, and this PR aligns to it:

  • Capability wins over selection: applicability is decided first; a non-applicable case is not-applicable regardless of only.
  • Deselected rows: the unselected remainder is emitted as {case, status: "deselected", detail: "only <filter>"} (exact harness.mjs shape, no other fields), never executed, counted in the new RunCounts.deselected.
  • RunCounts.selected: census cases matching the selection regardless of applicability (harness.mjs's selected), so consumers stop deriving it.
  • Empty-selection rule: an unsharded only matching nothing now throws (… matches no cases (empty selection is a run error)), as harness.mjs does; sharded stripes may legitimately match nothing. runSuite's doc comment already claimed this rule but only implemented the empty-census half.
  • CLI summary line reports deselected.

On the issue's own example (missing: ["hsm"], only: "gen" on polymorph-test's fixture suite) this yields the reference runners' 8 rows / na: 1, deselected: 5, selected: 2.

Also folded in (from this week's triage): README's xfail-class list named the retired cm705-reentrance class and omitted the live cm707-cancel (#250).

Tests

just test-ct-runner: 24 passed / 0 failed / 1 ignored (pre-existing). New/rewritten:

  • e2e: only reports the unselected remainder as deselected rows (row order, exact row shape, counts)
  • e2e: only matching nothing is a run error (unsharded)
  • tags e2e: capability wins over selection (N/A outranks deselected)
  • every existing RunCounts literal gains deselected/selected; the shard partition-identity test now covers deselected rows.

deno task check clean; version-guard local PASS; deno.lock untouched.

Versioning

No breaking/ct-runner label: RunCounts gains fields (additive), rows gain a status value the L4 schema already has, and the behavior change is a conformance fix toward the policy the package documents itself as mirroring. Judgement call — the consumer-visible deltas are that only runs now emit rows for every census case and a typo'd unsharded only throws instead of returning green; polymorph-test#106's selftest asserts the old behavior and is expected to flip. Relabel if you read that as caret-incompatible.

…tion (#286)

`runSuite` applied `only` before tag gating with a bare `continue`, so a
filtered-out case vanished from the row stream and a tags-excluded case
outside the selection vanished too. The reference runner (polymorph-test
js/viewer/harness.mjs `runCases`, docs/runner-policy.md "Selection is not
capability") does the opposite: applicability is decided first and a
non-applicable case is reported `not-applicable` regardless of `only`;
then the unselected remainder is emitted as `{case, status: "deselected",
detail: "only <filter>"}` rows — never executed, no provenance — so subset
runs still fold with the subsetting visible.

`RunCounts` gains `deselected` and `selected` (harness.mjs's counts), and
the reference's empty-selection rule now holds for an unsharded `only`
matching nothing (throws; sharded stripes may legitimately match nothing
and their coordinator guards over merged counts). The CLI summary line
reports deselected.

README: the xfail-class list named the retired cm705-reentrance class and
omitted the live cm707-cancel (#250).

Closes #286.
@lannbot
lannbot enabled auto-merge September 5, 2026 18:13
@lannbot
lannbot merged commit c7195d2 into main Sep 5, 2026
4 checks passed
@lannbot
lannbot deleted the fix-286-deselected-rows branch September 5, 2026 18:20
lannbot pushed a commit that referenced this pull request Sep 6, 2026
…s own facts

Five tests spelled out the identical full RunCounts tally for an
unfiltered run of the fixture suite while testing something else (golden
output, freshCases=false, shard-absent identity, bundle contents); every
additive field meant editing all of them, and the one outside ct-runner
broke CI on #287. The four ct-runner sites now share a constant in
support.ts. The release-bundle test is about the tags inventory surviving
bundling, so it asserts na and total — severing its coupling to the
tally's shape. Tests whose subject IS the counts keep explicit literals.
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.

ct-runner runSuite: only should report deselected rows and let capability win over selection (polymorph-test #89 policy)

2 participants