Skip to content

The emitted-artifact check had no subject; now it has one - #2796

Merged
gHashTag merged 3 commits into
masterfrom
w702-emitted-check
Aug 29, 2026
Merged

The emitted-artifact check had no subject; now it has one#2796
gHashTag merged 3 commits into
masterfrom
w702-emitted-check

Conversation

@gHashTag

Copy link
Copy Markdown
Owner

Refs #2762

check_emitted is the most thorough thing the catalog gate does — it compares every SSOT record against the emitted artifact, field by field. It has never run.

gen/ is in .gitignore, and aa01dd4f1 untracked those artifacts on purpose after they drifted (77 against an SSOT of 83). That left the check with nothing to read on every run since:

r.emitted = Some("absent: gen/numeric/formats_catalog.json not generated")

which is not a finding — and the suite prints findings only. Measured: zero occurrences of emitted artifacts in the output of the command that gates master. A check that could not run said so where no one was looking.

What changed

The generator is pure-stdlib Python, deterministic, and takes an output directory. When the artifact is absent the gate runs it into a temp dir and compares against that. A generator that cannot be found, or that exits non-zero, is a finding (emitted-unreadable), not a shrug.

Not a tautology, which is the first thing I checked

Generating the thing you then compare against the source is usually comparing a file to itself. It is not here: parse_records() in the gate and CATALOG_LINE in the generator are two independent parsers of the same text. The comparison is two accounts of one source, which is the only reason it can disagree.

Seen failing, on purpose

Patching a copy of the generator to write bits=999 for one record:

[emitted-agrees] gf10: SSOT bits=10 but emitted bits=999
before emitted artifacts: absent: … not generated
after emitted artifacts: 109 records, 436 numeric fields compared

Four hundred and thirty-six numeric fields, compared for the first time.

The generator is found by walking up from the catalog, not by counting directory levels — my first version computed specs/tools/gen_formats_catalog.py from .parent().parent() and reported a missing generator that was there all along.

GATE FAILURES stays 2: the comparison passes. What changed is that it runs.

cargo test --no-fail-fast     2437 passed, 0 failed
suite --ratchet               RATCHET: CLEAN, exit 0
check_catalog_integrity.py    exit 0
check_catalog_count.py        exit 0
check_seal_coverage.py        exit 0
check_specs_generate.py       exit 0
check_elab_ratchet.py         exit 0
check_withdrawn_live.py       exit 0

🤖 Generated with Claude Code

…has one

W702. `check_emitted` is the most thorough thing this gate does -- it compares
every SSOT record against the emitted artifact, field by field. It has never run.

`gen/` is in .gitignore, and aa01dd4 untracked those artifacts on purpose after
they drifted (77 against an SSOT of 83). That left the check with nothing to read
on every run since. It set

    r.emitted = Some("absent: gen/numeric/formats_catalog.json not generated")

which is NOT a finding -- and the suite prints findings only. Measured: ZERO
occurrences of "emitted artifacts" in the output of the command that gates
master. A check that could not run said so where no one was looking.

WHAT CHANGED. The generator is pure-stdlib Python, deterministic, and takes an
output directory. When the artifact is absent the gate runs it into a temp dir
and compares against that. A generator that cannot be found or that exits
non-zero is a FINDING (`emitted-unreadable`), not a shrug.

NOT A TAUTOLOGY, WHICH IS THE FIRST THING I CHECKED. Generating the thing you
then compare against the source is usually comparing a file to itself. It is not
here: `parse_records()` in this gate and `CATALOG_LINE` in the generator are two
independent parsers of the same text. The comparison is two accounts of one
source, which is the only reason it can disagree.

SEEN FAILING, ON PURPOSE. Patching a COPY of the generator to write bits=999 for
one record:

    [emitted-agrees] gf10: SSOT bits=10 but emitted bits=999

    emitted artifacts: absent: ... not generated     (before)
    emitted artifacts: 109 records, 436 numeric fields compared    (after)

Four hundred and thirty-six numeric fields, compared for the first time.

The generator is found by walking UP from the catalog, not by counting directory
levels: my first version computed `specs/tools/gen_formats_catalog.py` from
`.parent().parent()` and reported a missing generator that was there all along.

GATE FAILURES stays 2 -- the comparison passes. What changed is that it now runs.

    cargo test --no-fail-fast     2437 passed, 0 failed
    suite --ratchet               RATCHET: CLEAN, exit 0
    check_catalog_integrity.py    exit 0
    check_catalog_count.py        exit 0
    check_seal_coverage.py        exit 0
    check_specs_generate.py       exit 0
    check_elab_ratchet.py         exit 0
    check_withdrawn_live.py       exit 0

Refs #2762

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

📓 NotebookLM Notebook linked to this PR

This notebook contains session context, decisions, and artifacts for this work.

@github-actions

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-08-29 10:42:13 UTC

Summary

Status Count
Total Open PRs 8
PRs with Failing Checks 7
PRs with All Checks Green 1
READY 0
FAILING 7
PENDING 0

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=d25ac0cc159e != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

W702, second half. Measured before: `t27c catalog-gate; echo $?` prints
`FINDINGS 3` and gives EXIT=0. The function's only terminator was `Ok(())`.

The CLI is where a human runs this gate by hand, and it was telling every one of
them that a run with three findings had succeeded. It now exits non-zero with the
same arithmetic the suite uses:

    Error: 2 unexpected catalog finding(s) (1 allowed as debt)

The allowlist moved from a private const in suite.rs to `catalog_gate::ALLOWED`,
so the CLI and the suite cannot drift into disagreeing about which findings are
debt. One list, one meaning, read by both.

And its own `--help` said "whose 83 records live in structured comments". The
live number is 109 and has been since the three families were added -- a ruler
describing a smaller catalog than the one it measures.

Nothing in CI invokes this command, so the change cannot turn a workflow red; it
changes what a person at a terminal is told.

    t27c catalog-gate         exit 0 -> exit 1 (unchanged findings)
    suite --ratchet           RATCHET: CLEAN, GATE FAILURES 2 -- unmoved
    cargo test --no-fail-fast 2437 passed, 0 failed

Refs #2762

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-08-29 10:57:58 UTC

Summary

Status Count
Total Open PRs 9
PRs with Failing Checks 7
PRs with All Checks Green 2
READY 0
FAILING 7
PENDING 0

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=d25ac0cc159e != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

@github-actions

Copy link
Copy Markdown
Contributor

📓 NotebookLM Notebook linked to this PR

This notebook contains session context, decisions, and artifacts for this work.

@github-actions

Copy link
Copy Markdown
Contributor

📓 NotebookLM Notebook linked to this PR

This notebook contains session context, decisions, and artifacts for this work.

@github-actions

Copy link
Copy Markdown
Contributor

PR Dashboard

Generated at: 2026-08-29 11:15:10 UTC

Summary

Status Count
Total Open PRs 8
PRs with Failing Checks 7
PRs with All Checks Green 1
READY 0
FAILING 7
PENDING 0

Seal Status

  • ⚠️ STALE -- sha256(compiler.rs)=d25ac0cc159e != manifest seal=87e5cbd3ad94.
    The committed NMSE numbers were certified against an older compiler.rs.
    Run scripts/reseal-check.sh locally for the two-step reseal command (advisory; not a merge gate).

@github-actions github-actions Bot mentioned this pull request Aug 29, 2026
@gHashTag
gHashTag merged commit 04991d9 into master Aug 29, 2026
33 checks passed
@gHashTag
gHashTag deleted the w702-emitted-check branch August 29, 2026 11:25
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