the exit-status-zero rule gets one owner #1218

Closed
opened 2026-10-20 18:22:50 +00:00 by jared · 2 comments
Owner

Problem

The rule "exit status 0 means pass" has six owners in os-sdlc: Gate::CommandResult#success?, two sites in OsSdlc::StepOutcome, OsSdlc::StepResult, Lint::Result#pass?, and Lint::ExitClassification. Structure ruling S1 cut the Lint-to-Gate cycle by moving ExitClassification to Lint; that removed 71 cycle edges but left the rule with six homes, five of them unnamed. A change to the rule (for example, exit 1 with a green report counts as pass) needs six edits and no test fails when one is missed.

Observed

grep -rn "exit_status.zero?" plugins/os-sdlc/lib/os_sdlc | wc -l
6

Reproduce

n/a: design ticket; sites listed above.

Approach

Give the rule one owner. The ticket first named Gate::CommandResult#success? as the candidate owner. That owner would bring back the Lint-to-Gate edge that S1 (#1165) cut, because Lint::ExitClassification and Lint::Result would then call into Gate. The owner is Lint::ExitClassification.pass?. Gate already references Lint, so no new cycle appears.
Owner predicted 2026-10-21 by /os-me:predict; open for Jared's review.

Required work:

  1. Lint::ExitClassification.pass? is the one definition of the exit rule — check: present def self.pass? in plugins/os-sdlc/lib/os_sdlc/lint/exit_classification.rb
  2. StepOutcome asks the owner — check: absent exit_status.zero? in plugins/os-sdlc/lib/os_sdlc/step_outcome.rb
  3. StepResult asks the owner — check: absent exit_status.zero? in plugins/os-sdlc/lib/os_sdlc/step_result.rb
  4. Gate::CommandResult asks the owner — check: absent exit_status.zero? in plugins/os-sdlc/lib/os_sdlc/gate/command_result.rb
  5. Lint::Result asks the owner — check: absent exit_status.zero? in plugins/os-sdlc/lib/os_sdlc/lint.rb

Acceptance criteria

  1. Given a command result with exit status 0, when any gate step or lint assert classifies it, then they all ask the one owner and agree.

Owner sketch

module OsSdlc
  class Lint
    module ExitClassification
      def self.pass?(exit_status) = exit_status.zero?
      def self.classify(exit_status) = pass?(exit_status) ? :pass : :fail
    end
  end
end

Origin

  • Trigger: run 3 retrospective smell analysis of cycle-edges (S1, #1165)
  • Improvised this session: none
  • Chain: five copies of one rule ← the cycle cut moved the named copy without searching for the body ← DESIGN (structure-wave.md cycle row rule, now amended to search the body)
  • Root candidate: none found; searched exit status, zero?, ExitClassification, CommandResult, success?, duplication

VERDICT: CREATE

  • Where: plugins/os-sdlc/lib/os_sdlc/gate/command_result.rb
  • Session: 86f833b9-4ecf-435e-b24d-0644ff554982
  • Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os/86f833b9-4ecf-435e-b24d-0644ff554982.jsonl
## Problem The rule "exit status 0 means pass" has six owners in os-sdlc: `Gate::CommandResult#success?`, two sites in `OsSdlc::StepOutcome`, `OsSdlc::StepResult`, `Lint::Result#pass?`, and `Lint::ExitClassification`. Structure ruling S1 cut the Lint-to-Gate cycle by moving `ExitClassification` to Lint; that removed 71 cycle edges but left the rule with six homes, five of them unnamed. A change to the rule (for example, exit 1 with a green report counts as pass) needs six edits and no test fails when one is missed. ## Observed ``` grep -rn "exit_status.zero?" plugins/os-sdlc/lib/os_sdlc | wc -l ``` ``` 6 ``` ## Reproduce n/a: design ticket; sites listed above. ## Approach Give the rule one owner. The ticket first named `Gate::CommandResult#success?` as the candidate owner. That owner would bring back the Lint-to-Gate edge that S1 (#1165) cut, because `Lint::ExitClassification` and `Lint::Result` would then call into Gate. The owner is `Lint::ExitClassification.pass?`. Gate already references Lint, so no new cycle appears. Owner predicted 2026-10-21 by /os-me:predict; open for Jared's review. Required work: 1. `Lint::ExitClassification.pass?` is the one definition of the exit rule — check: present `def self.pass?` in `plugins/os-sdlc/lib/os_sdlc/lint/exit_classification.rb` 2. `StepOutcome` asks the owner — check: absent `exit_status.zero?` in `plugins/os-sdlc/lib/os_sdlc/step_outcome.rb` 3. `StepResult` asks the owner — check: absent `exit_status.zero?` in `plugins/os-sdlc/lib/os_sdlc/step_result.rb` 4. `Gate::CommandResult` asks the owner — check: absent `exit_status.zero?` in `plugins/os-sdlc/lib/os_sdlc/gate/command_result.rb` 5. `Lint::Result` asks the owner — check: absent `exit_status.zero?` in `plugins/os-sdlc/lib/os_sdlc/lint.rb` ## Acceptance criteria 1. Given a command result with exit status 0, when any gate step or lint assert classifies it, then they all ask the one owner and agree. ## Owner sketch ```ruby module OsSdlc class Lint module ExitClassification def self.pass?(exit_status) = exit_status.zero? def self.classify(exit_status) = pass?(exit_status) ? :pass : :fail end end end ``` ## Origin - Trigger: run 3 retrospective smell analysis of cycle-edges (S1, #1165) - Improvised this session: none - Chain: five copies of one rule ← the cycle cut moved the named copy without searching for the body ← DESIGN (structure-wave.md cycle row rule, now amended to search the body) - Root candidate: none found; searched exit status, zero?, ExitClassification, CommandResult, success?, duplication VERDICT: CREATE - Where: plugins/os-sdlc/lib/os_sdlc/gate/command_result.rb - Session: 86f833b9-4ecf-435e-b24d-0644ff554982 - Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os/86f833b9-4ecf-435e-b24d-0644ff554982.jsonl
Author
Owner

Body corrected to main: 6 sites, OsSdlc:: names, owner predicted Lint::ExitClassification.pass?; routed to /os-sdlc:fast-batch (fast-batch-5).

Body corrected to main: 6 sites, OsSdlc:: names, owner predicted Lint::ExitClassification.pass?; routed to /os-sdlc:fast-batch (fast-batch-5).
Author
Owner

Resolution

Done: Lint::ExitClassification.pass?(exit_status) owns the exit-0 pass rule; all six exit_status.zero? sites call it (fast-batch-6). Owner predicted by /os-me:predict while Jared was away; recorded in collaborator-rulings.tsv.

Evidence: main 8899b2e0 (commits 2da31db8, 3c0a3ab5); memo docs/crc/os-sdlc/fast-batch-6/finding-a-exit-status-owner.md; suite 2347 runs 0 failures; stranger reviews standards+spec found no missing or wrong item for finding A.

Follow-ups: none: the SQL form in StepResult.failing and the neutral ExitStatus owner alternative are recorded in the session handoff for Jared's review of the predicted owner.

## Resolution **Done:** Lint::ExitClassification.pass?(exit_status) owns the exit-0 pass rule; all six exit_status.zero? sites call it (fast-batch-6). Owner predicted by /os-me:predict while Jared was away; recorded in collaborator-rulings.tsv. **Evidence:** main 8899b2e0 (commits 2da31db8, 3c0a3ab5); memo docs/crc/os-sdlc/fast-batch-6/finding-a-exit-status-owner.md; suite 2347 runs 0 failures; stranger reviews standards+spec found no missing or wrong item for finding A. **Follow-ups:** none: the SQL form in StepResult.failing and the neutral ExitStatus owner alternative are recorded in the session handoff for Jared's review of the predicted owner.
jared closed this issue 2026-10-21 21:38:42 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
jared/cc-os#1218
No description provided.