Found at sprint-planning time for #498 Lane B (mission iteration 138). Both findings were
reproduced first-party by the controller after the planner surfaced them, each with a
known-positive control so the zeros are measurements and not broken patterns.
1. make check-file-sizes enumerates find internal cmd only
make/code-health.mk:126 — the gate body is:
for file in $$(find internal cmd -name "*.go"); do
Measured:
| Query |
Result |
find internal cmd -name '*.go' | grep -c 'internal/apiserver/' |
45 (known-positive: the gate does work) |
find internal cmd -name '*.go' | grep -cE '^(runtime|std)/' |
0 |
find runtime std -name '*.go' | wc -l |
6 — the files genuinely exist |
So every first-party Go package outside internal/ and cmd/ — today runtime/, std/,
testutil/, scripts/, tools/* — has no 800-line enforcement at all. This is not
hypothetical: #498 Lane B adds a new top-level public package serveapi/, and its design doc's
acceptance criterion "make check-file-sizes passes" would have passed identically if
serveapi/serveapi.go were 5,000 lines. The sprint plan works around it with an explicit
find serveapi -name '*.go' | xargs wc -l assertion, but that is a per-sprint patch of a
repo-wide gap.
2. make check-boundaries iterates three fixed package sets, and apiserver is in none
scripts/check_boundaries.sh enumerates CORE_PKGS, DASHBOARD_PKGS, CORE_SURFACE_PKGS.
| Query |
Result |
grep -c apiserver scripts/check_boundaries.sh |
0 |
grep -c serveapi scripts/check_boundaries.sh |
0 |
grep -c parser scripts/check_boundaries.sh |
4 (control — the instrument matches) |
bash scripts/check_boundaries.sh |
rc=0, OK: no architecture boundary violations. |
The gate therefore passes whether or not internal/apiserver (or a future serveapi/) imports the
compiler core directly. The script's own header comment already anticipates this failure class:
it warns that a wrong package value "silently makes the gate pass on every import match".
Why this matters beyond the two gates
Both are vacuous-pass defects: the gate runs, exits 0, and is quoted downstream as evidence for
a claim it never covered. The #498 Lane B design doc had already measured the boundary-gate gap
(its row V18) and still listed make check-boundaries as an acceptance criterion — the measurement
was recorded and the conclusion built on it was not corrected.
Suggested fix
- Derive both gates' file lists from
go list ./... (or find . -name '*.go' minus vendor/
worktrees/node_modules), not from a hardcoded directory pair / package array.
- Add an anti-vacuity floor to each: assert the enumerated file count is above a known minimum and
exit 1 loudly if the list comes back short, so a future re-scoping cannot silently empty it.
- Add a self-test fixture that a deliberately-oversized file outside
internal/+cmd/ is caught.
Not urgent enough to outrank the queue; filing so it is not re-discovered a third time.
Found at sprint-planning time for
#498Lane B (mission iteration 138). Both findings werereproduced first-party by the controller after the planner surfaced them, each with a
known-positive control so the zeros are measurements and not broken patterns.
1.
make check-file-sizesenumeratesfind internal cmdonlymake/code-health.mk:126— the gate body is:Measured:
find internal cmd -name '*.go' | grep -c 'internal/apiserver/'find internal cmd -name '*.go' | grep -cE '^(runtime|std)/'find runtime std -name '*.go' | wc -lSo every first-party Go package outside
internal/andcmd/— todayruntime/,std/,testutil/,scripts/,tools/*— has no 800-line enforcement at all. This is nothypothetical:
#498Lane B adds a new top-level public packageserveapi/, and its design doc'sacceptance criterion "
make check-file-sizespasses" would have passed identically ifserveapi/serveapi.gowere 5,000 lines. The sprint plan works around it with an explicitfind serveapi -name '*.go' | xargs wc -lassertion, but that is a per-sprint patch of arepo-wide gap.
2.
make check-boundariesiterates three fixed package sets, andapiserveris in nonescripts/check_boundaries.shenumeratesCORE_PKGS,DASHBOARD_PKGS,CORE_SURFACE_PKGS.grep -c apiserver scripts/check_boundaries.shgrep -c serveapi scripts/check_boundaries.shgrep -c parser scripts/check_boundaries.shbash scripts/check_boundaries.shOK: no architecture boundary violations.The gate therefore passes whether or not
internal/apiserver(or a futureserveapi/) imports thecompiler core directly. The script's own header comment already anticipates this failure class:
it warns that a wrong package value "silently makes the gate pass on every import match".
Why this matters beyond the two gates
Both are vacuous-pass defects: the gate runs, exits 0, and is quoted downstream as evidence for
a claim it never covered. The
#498Lane B design doc had already measured the boundary-gate gap(its row V18) and still listed
make check-boundariesas an acceptance criterion — the measurementwas recorded and the conclusion built on it was not corrected.
Suggested fix
go list ./...(orfind . -name '*.go'minus vendor/worktrees/node_modules), not from a hardcoded directory pair / package array.
exit 1loudly if the list comes back short, so a future re-scoping cannot silently empty it.internal/+cmd/is caught.Not urgent enough to outrank the queue; filing so it is not re-discovered a third time.