Defect
scripts/tests/docstring-scan-test.sh was added in #1073 (4b2a347). Its calibration step asserts that commit 1cc72cdc80c9 is present. That commit is PR #1034's pre-squash head. #1034 was squash-merged as c56f4ecc, so 1cc72cdc80c9 lives only under refs/pull/1034/head and no clone of main contains it, however deep. The remedy the test prints, "fetch full history", cannot cure it, because Self Test already checks out with fetch-depth: 0.
Measured:
Cure
On a miss, fetch the calibration commit by full SHA, then re-check. Keep the fail-closed bad assertion when the fetch fails.
- Use
git fetch --quiet --no-tags origin <full sha> without --depth. In a complete clone, --depth writes .git/shallow and truncates main's history for every later test in the job.
- The calibration commit and its CodeRabbit cross-reference (13 functions / 2 files / 0.00% / 3 skipped) stay unchanged.
Acceptance criteria
The cure is folded into #1088. It can't land separately under the fully-green rule, because a standalone PR would be red on #1088's other cures.
🤖 Generated with Claude Code
https://claude.ai/code/session_01QYY8Gp4v4x2J7iSNn1vZ57
Defect
scripts/tests/docstring-scan-test.shwas added in #1073 (4b2a347). Its calibration step asserts that commit1cc72cdc80c9is present. That commit is PR #1034's pre-squash head. #1034 was squash-merged asc56f4ecc, so1cc72cdc80c9lives only underrefs/pull/1034/headand no clone of main contains it, however deep. The remedy the test prints, "fetch full history", cannot cure it, because Self Test already checks out withfetch-depth: 0.Measured:
74d2f66ffails (run 36741131926). Two test files fail: the stale registry (main red: REGISTRY source_hash drift after #1072/#1075 reds Registry Verify and Repo self-tests (and skips the lock-gate pin guard) #1092) and this one,FAIL calibration commit present (fetch full history).Cure
On a miss, fetch the calibration commit by full SHA, then re-check. Keep the fail-closed
badassertion when the fetch fails.git fetch --quiet --no-tags origin <full sha>without--depth. In a complete clone,--depthwrites.git/shallowand truncates main's history for every later test in the job.Acceptance criteria
docstring-scan-test.shpasses in CI on afetch-depth: 0checkout of main, and the calibration row reports files=2, functions=13, documented=0, skipped=3, coverage=0.00%..git/shallowin the common dir).The cure is folded into #1088. It can't land separately under the fully-green rule, because a standalone PR would be red on #1088's other cures.
🤖 Generated with Claude Code
https://claude.ai/code/session_01QYY8Gp4v4x2J7iSNn1vZ57