Repository navigation
Description
What
The SOP-002 decoy suites for Go (tests/decoys/test_decoy_go.py, arriving on main with #9464) found real engine leaks. Each is filed as its own issue and locked in the suite as @pytest.mark.xfail(strict=True): fixing a leak makes its test pass unexpectedly, which fails the suite until the marker is removed. That is the signal the leak is closed. Part of the epic #8863 (keyword-family validity).
Leaks
- Go macros: the rule matches only //go: pragma comments, which are blanked before the rule runs (dead outside a raw string) #9429 Go macros: the rule matches only //go: pragma comments, which are blanked before the rule runs (dead outside a raw string)
- Go api: the handler-signature arm has no word boundary on http.ResponseWriter / gin.Context / echo.Context #9430 Go api: the handler-signature arm has no word boundary on http.ResponseWriter / gin.Context / echo.Context
- Go safety_bypasses: a variable ending in an underscore (my_ = x, result_, err = f()) counts as a blank-identifier discard #9431 Go safety_bypasses: a variable ending in an underscore (my_ = x, result_, err = f()) counts as a blank-identifier discard
- Go scientific: the math/cmplx., math/rand. and crypto/rand. arms match text no Go program contains; cmplx.Abs and rand.Intn are not counted #9432 Go scientific: the math/cmplx., math/rand. and crypto/rand. arms match text no Go program contains; cmplx.Abs and rand.Intn are not counted
Note
#9429 is a DEAD rule (macros can only fire inside a multi-line raw string): decide with the contract whether to redesign it so authentic Go fires it, or remove it (the dead-key audit applies); a contract that is draft or silent is a question for #8862.
How
Follow .claude/skills/family-validity-fix/SKILL.md, docs/agents/family-validity-checklist.md and docs/agents/decoy-spec-protocol.md (SOP-002). Rules live in gitgalaxy/standards/language_standards/languages/go.py. First check that the suite is on main (ls tests/decoys/test_decoy_go.py); if it is not yet, the PR it arrives in (#9464) has not merged: wait. Per leak: reproduce with the snippet in the leak issue, name the cause class, read the contract, make the smallest fix, then remove that test's xfail marker, flip the cell's gate in tests/family_validity_baseline.json from leak to pass (decoys..), regenerate the charts (python tests/tools/family_validity_chart.py --write), run the suite both directions, time CPU before and after (seconds, on keyword-rosetta and language-crucible), and bless the goldens once for the PR. If keyword-rosetta counts move, label rosetta:rebless-owed. One PR for this language only, with one Closes #N line per leak it fixes. A real fix needs no rule contract change; where the contract is draft or silent, file the question on #8862 instead of guessing.
The suite is a measurement: do not weaken a test to make a fix pass, and do not skip a leak because the fix is awkward.
🤖 Generated with Claude Code
Activity