Skip to content

M5 Phase 3: the demo's review arc names a starter, and says nothing when it cannot find it - #63

Merged
kjpatel merged 1 commit into
mainfrom
m5-phase3-fixtures-demo-c
Aug 6, 2026
Merged

M5 Phase 3: the demo's review arc names a starter, and says nothing when it cannot find it#63
kjpatel merged 1 commit into
mainfrom
m5-phase3-fixtures-demo-c

Conversation

@kjpatel

@kjpatel kjpatel commented Aug 6, 2026

Copy link
Copy Markdown
Owner

Scoping the last three demo suites turned up the dependency that blocks two of them — and it is exactly the kind this phase exists to remove.

The finding

demo/app.py declares REVIEW_SOURCE_SCENARIO = "notice-ny", plus a matching scenario id, case id and title. The demo is toolkit (D2), so that is a teaching scenario's name compiled into it. _ingest_review_case is wrapped in except Exception: pass, so pointing DULY_DEMO_CONTENT anywhere else makes the arc quietly not appear — no error, no log line, one fewer scenario in a list nobody counts.

Degrading quietly is the right behaviour for a missing demonstration. That is precisely why hardcoding which demonstration went unnoticed: from outside, "this deployment has no review scenario" and "this deployment has one but we only look for notice-ny" are indistinguishable.

Why this PR routes rather than fixes

I started the fix — derive the source from whichever scenario carries a below-floor extraction, preferring notice-ny so this repository's demo stays byte-unchanged — and backed it out. Four constants, nine call sites in app.py, and one constant test_review_arc.py imports.

A half-refactored app.py is worse than a routed finding, and the finding is what the next PR needs to start from. So: a plan task (4b(ii)c-0) carrying the shape of the change, a CLAUDE.md gotcha so it cannot be rediscovered by surprise, and a changelog paragraph on why a silent failure hid a hardcoded name.

Sequencing this settles: test_rules_api (31 failures, the largest) does not touch the arc and can go first. test_evidence_api and test_review_arc both assert on it and cannot.

Also

The one example test in test_content_roots is now labelled as one — its subject is what this repository happens to ship, so it moves with the six packs rather than being repointed. Everything else in that file asserts toolkit behaviour and stays.

Verification

975 passed, 7 skipped
verified 351 cases              # byte-for-byte
git diff -- golden/ fixtures/   # empty

Documentation pass run per CLAUDE.md's definition of done — including the sweep for every doc naming the constants, piped to wc -l rather than head (one hit, the plan).

🤖 Generated with Claude Code

…hen it cannot find it

Scoping the last three demo suites turned up the dependency that blocks two of
them, and it is the kind this phase exists to remove.

demo/app.py declares REVIEW_SOURCE_SCENARIO = "notice-ny", plus a matching
scenario id, case id and title. The demo is toolkit (D2), so that is a teaching
scenario's name compiled into it. _ingest_review_case is wrapped in
`except Exception: pass`, so pointing DULY_DEMO_CONTENT anywhere else makes the
arc quietly not appear — no error, no log line, one fewer scenario in a list
nobody counts.

Degrading quietly is the right behaviour for a missing demonstration. That is
precisely why hardcoding *which* demonstration went unnoticed: from outside,
"this deployment has no review scenario" and "this deployment has one but we
only look for notice-ny" are indistinguishable.

I started the fix — derive the source from whichever scenario carries a
below-floor extraction, preferring notice-ny so this repository's demo is
byte-unchanged — and backed it out. Four constants, nine call sites and one
constant test_review_arc.py imports; a half-refactored app.py is worse than a
routed finding, and the finding is what the next PR needs to start from.

So this PR routes rather than fixes: a plan task (4b(ii)c-0) with the shape of
the change, a CLAUDE.md gotcha so it cannot be rediscovered by surprise, and a
changelog paragraph on why a silent failure hid a hardcoded name. test_rules_api
does not depend on the arc and can go first; the other two cannot.

Also: the one example test in test_content_roots is labelled as one — its
subject is what this repository happens to ship, so it moves with the six packs
rather than being repointed.

Verification: 975 passed, 7 skipped; verify 351 byte-for-byte; golden/ and
fixtures/ untouched. Documentation pass run per CLAUDE.md's definition of done,
including the sweep for every doc naming the constants (one hit, the plan).

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@kjpatel
kjpatel merged commit b7a36a9 into main Aug 6, 2026
6 checks passed
@kjpatel
kjpatel deleted the m5-phase3-fixtures-demo-c branch August 6, 2026 14:57
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