Files
jray-project/scripts
dtourolleandClaude Opus 5 041961c8c6 Shared traceability tooling, generalised for every component
Moves the extractor, its tests and the gate from scene-actor-extraction into
the project home, so all three components run one implementation rather than
each growing its own. The gate logic is unchanged; what changes is that the
two repo-specific constants become arguments.

Both were hard blockers rather than inconveniences. LOCAL_TYPES was fixed at
the extraction set, so a register using UR/DR parsed to zero requirements;
SOURCE_SUFFIXES covered C++/Python only, so a Rust or C# tree scanned zero
files. The gate correctly refuses to report coverage in either state, which is
how both surfaced. They are now --types, --suffixes and --scan-roots, with the
extraction defaults preserved: that repo runs unchanged with no flags.

traceability-gate.sh gains REPO_ROOT, REQUIREMENTS, TYPES, SUFFIXES and
SCAN_ROOTS environment overrides. Its REPO_ROOT default of SCRIPT_DIR/../..
is correct when the tooling sits in the repo it checks, but resolves to the
submodule itself once vendored, so a consuming repo must set it.

Fixes a latent bug found while testing the override: iter_source_files bound
SCAN_ROOTS as a default argument, evaluated at import, so configure_scan_roots
could never affect it.

58 tests pass. The two that read a live register now take LIVE_REGISTER from
the environment and skip without it — they asserted against AR-012/AR-027,
which belong to scene-actor-extraction rather than to a shared tool.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-30 18:23:41 +02:00
..