The path check piped git diff into grep -q under pipefail: on a match grep
exits early, git diff can die of SIGPIPE, and the pipeline's failure read as
"no match", so the tests were skipped exactly when they were needed.
chunkstore-scope.sh writes the NUL-delimited list to a file and reads it to
its end, as docs-only-scope.sh does; an error of the check runs the tests.
Its self-test covers a match listed after 20000 other files, a deletion, a
look-alike prefix and an unknown revision. Each filtered go test must PASS at
least one test, so a filter that matches nothing fails instead of passing.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The classification moves into .github/scripts/docs-only-scope.sh: it
writes git's NUL-delimited list to a file and reads it to the end, so no
pipe stops early and a writer's error cannot read as "no other file". A
failed git diff exits nonzero, and the step then runs the tests.
docs-only-scope-test.sh runs first in the step, against real commits:
docs only, docs and a test file, no file, a docs-like prefix, README, a
move out of docs, a docs deletion, 20000 docs files with one other file
last, an unknown revision (an error), and that test.yml applies the check
only to a pull request's process suite and gates all four process steps.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>