Repository navigation
Description
What
The SOP-002 decoy suites for Ruby (tests/decoys/test_decoy_ruby.py, arriving on main with #9465) 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
- Ruby (all families): =begin ... =end block comments leak into the code stream (auth_middleware, comprehensions, import, telemetry) #9435 Ruby (all families): =begin ... =end block comments leak into the code stream (auth_middleware, comprehensions, import, telemetry)
- Ruby (all families): the __END__ DATA section is counted as code (auth_middleware, comprehensions, import, telemetry) #9436 Ruby (all families): the END DATA section is counted as code (auth_middleware, comprehensions, import, telemetry)
- Ruby telemetry: a bare logger.info / @logger.warn never fires (rule needs an identifier prefix before 'logger') #9437 Ruby telemetry: a bare logger.info / @logger.warn never fires (rule needs an identifier prefix before 'logger')
- Ruby import: YAML.load / JSON.load calls and a variable named load count as an import #9438 Ruby import: YAML.load / JSON.load calls and a variable named load count as an import
- Ruby auth_middleware: def authenticate_user! (a definition) counts as an authentication site #9440 Ruby auth_middleware: def authenticate_user! (a definition) counts as an authentication site
- Ruby comprehensions: .inject(0) { } and .each_with_object([]) { } never fire (block opener must follow the method name directly) #9442 Ruby comprehensions: .inject(0) { } and .each_with_object([]) { } never fire (block opener must follow the method name directly)
Note
The fleet also edits ruby.py for the red cells of #9331: check gh pr list --search ruby.py for an open Ruby PR before you start and rebase after it.
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/ruby.py. First check that the suite is on main (ls tests/decoys/test_decoy_ruby.py); if it is not yet, the PR it arrives in (#9465) 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