Commit 4bb92bf
committed
fix(governance): scan a clean caller tree — don't scan the .standards-checkout tooling
Follow-up to #455/#464. The baseline gate checks out standards' scripts/ into
`.standards-checkout/` (to get apply-baseline.sh), but that directory lives
INSIDE the caller's working tree — so `hypatia-cli.sh scan .` scanned it too and
reported standards' OWN files as the caller's findings. On neurophone#172 this
surfaced 4 phantom findings from the tooling checkout: a banned-language `.ts`
(critical) and three `shell_download` bootstrap.sh scripts (high), none of which
are the caller's code. Every adopting repo would inherit these.
Fix: copy apply-baseline.sh to $RUNNER_TEMP and `rm -rf .standards-checkout`
BEFORE the scan, then run the filter from $RUNNER_TEMP. hypatia now only ever
sees the caller's own tree; the tooling checkout can't pollute the finding set.
Completes the estate-wide gate: with #455 (baseline consulted) + #464 (filter
actually runs) + this (clean scan tree), validate-hypatia-baseline finally
behaves as intended — suppress a repo's acknowledged baseline entries, fail on
genuinely-new findings, and never conflate the tooling with the repo under audit.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0172RBMz3qYjb1ttzD2i7RNh1 parent f81bb04 commit 4bb92bf
1 file changed
Lines changed: 9 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
128 | 128 | | |
129 | 129 | | |
130 | 130 | | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
131 | 139 | | |
132 | 140 | | |
133 | 141 | | |
| |||
160 | 168 | | |
161 | 169 | | |
162 | 170 | | |
163 | | - | |
| 171 | + | |
164 | 172 | | |
165 | 173 | | |
166 | 174 | | |
| |||
0 commit comments