os-sdlc: move the shared Thor base out of Crc to OsSdlc::CLI (structure only) #1681

Closed
opened 2026-11-10 21:21:27 +00:00 by jared · 2 comments
Owner

Problem

The commandless Thor base class of os-sdlc is OsSdlc::Crc::CLI (plugins/os-sdlc/lib/os_sdlc/crc/cli.rb). Its helpers are OsSdlc::Crc::CLI::Shell, OsSdlc::Crc::CLI::Invocation, and OsSdlc::Crc::CommandResult. None of the four holds crc-specific code. The next tickets move fast-gate, detector, collaborator-pass, system-model, and the mutation commands onto Thor. A class such as OsSdlc::Detector::CLI must not inherit from a class in the Crc namespace. Ruling 126 (docs/decisions/rulings.tsv) places the base in a neutral namespace before those tickets.

Reproduce

n/a: structure ticket. No behavior changes.

Approach

The language is Ruby. The suite command is ruby test/all.rb, run from plugins/os-sdlc. This is a structure change: rename and move only. Behavior stays byte-identical.

  • OsSdlc::Crc::CLI (the commandless base) becomes OsSdlc::CLI in lib/os_sdlc/cli.rb.
  • OsSdlc::Crc::CLI::Shell becomes OsSdlc::CLI::Shell in lib/os_sdlc/cli/shell.rb.
  • OsSdlc::Crc::CLI::Invocation becomes OsSdlc::CLI::Invocation in lib/os_sdlc/cli/invocation.rb.
  • OsSdlc::Crc::CommandResult becomes OsSdlc::CommandResult in lib/os_sdlc/command_result.rb. OsSdlc::Gate::CommandResult is a different class and keeps its name; code inside module Gate continues to resolve CommandResult to Gate::CommandResult.
  • OsSdlc::Crc::LedgerGate stays in Crc: it is crc-specific.
  • Each Crc::<Concept>::CLI class inherits from OsSdlc::CLI. Every reference in lib/, bin/, and test/ follows the new names. Test files that are named for the moved classes move with them (for example test/crc/cli_survivor_test.rb, test/crc/command_result_test.rb) when their subject is one of the four classes.
  • The Zeitwerk inflection "cli" => "CLI" already exists and covers the new path.

Required work:

  1. present class CLI < Thor in plugins/os-sdlc/lib/os_sdlc/cli.rb
  2. present class Shell in plugins/os-sdlc/lib/os_sdlc/cli/shell.rb
  3. present class Invocation in plugins/os-sdlc/lib/os_sdlc/cli/invocation.rb
  4. present CommandResult = Data.define in plugins/os-sdlc/lib/os_sdlc/command_result.rb
  5. absent class CLI < Thor in plugins/os-sdlc/lib/os_sdlc/crc/cli.rb
  6. absent Crc::CommandResult in plugins/os-sdlc/lib/os_sdlc/**/*.rb
  7. absent Crc::CLI::Invocation in plugins/os-sdlc/lib/os_sdlc/**/*.rb

Out of scope

Any new Thor command, any change to Project, and any change to error text or exit codes.

Origin

Trigger: n/a: design ticket from ruling 126, not a run that showed a fault
Improvised this session: none
Chain: Detector::CLI would inherit from Crc::CLI ← the shared Thor base was built inside Crc for the crc commands only (ruling 121) ← non-crc commands now move to Thor (owner ruling of 2026-11-10)
Session: a48658d5-b566-40ce-8257-ebeabf56f7e1
Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os--claude-worktrees-ticket-1677/a48658d5-b566-40ce-8257-ebeabf56f7e1.jsonl
Where: plugins/os-sdlc/lib/os_sdlc/crc/cli.rb (OsSdlc::Crc::CLI), plugins/os-sdlc/lib/os_sdlc/crc/cli/invocation.rb, plugins/os-sdlc/lib/os_sdlc/crc/cli/shell.rb, plugins/os-sdlc/lib/os_sdlc/crc/command_result.rb
Root candidate: none found; parent decision ticket #1646
Approved by: predicted ruling 126 (confidence 85), part of the Thor-entry change that Jared ordered on 2026-11-10 ("List the changes we are making. Then implement them.").

VERDICT: CREATE
REASON: The slice follows from ruling 126, inside the Thor-entry change the owner ordered on 2026-11-10. The move is structural and needed before the other commands can inherit from the base. No open ticket covers the same mechanism.

## Problem The commandless Thor base class of os-sdlc is `OsSdlc::Crc::CLI` (`plugins/os-sdlc/lib/os_sdlc/crc/cli.rb`). Its helpers are `OsSdlc::Crc::CLI::Shell`, `OsSdlc::Crc::CLI::Invocation`, and `OsSdlc::Crc::CommandResult`. None of the four holds crc-specific code. The next tickets move `fast-gate`, `detector`, `collaborator-pass`, `system-model`, and the mutation commands onto Thor. A class such as `OsSdlc::Detector::CLI` must not inherit from a class in the `Crc` namespace. Ruling 126 (`docs/decisions/rulings.tsv`) places the base in a neutral namespace before those tickets. ## Reproduce n/a: structure ticket. No behavior changes. ## Approach The language is Ruby. The suite command is `ruby test/all.rb`, run from `plugins/os-sdlc`. This is a structure change: rename and move only. Behavior stays byte-identical. - `OsSdlc::Crc::CLI` (the commandless base) becomes `OsSdlc::CLI` in `lib/os_sdlc/cli.rb`. - `OsSdlc::Crc::CLI::Shell` becomes `OsSdlc::CLI::Shell` in `lib/os_sdlc/cli/shell.rb`. - `OsSdlc::Crc::CLI::Invocation` becomes `OsSdlc::CLI::Invocation` in `lib/os_sdlc/cli/invocation.rb`. - `OsSdlc::Crc::CommandResult` becomes `OsSdlc::CommandResult` in `lib/os_sdlc/command_result.rb`. `OsSdlc::Gate::CommandResult` is a different class and keeps its name; code inside `module Gate` continues to resolve `CommandResult` to `Gate::CommandResult`. - `OsSdlc::Crc::LedgerGate` stays in `Crc`: it is crc-specific. - Each `Crc::<Concept>::CLI` class inherits from `OsSdlc::CLI`. Every reference in `lib/`, `bin/`, and `test/` follows the new names. Test files that are named for the moved classes move with them (for example `test/crc/cli_survivor_test.rb`, `test/crc/command_result_test.rb`) when their subject is one of the four classes. - The Zeitwerk inflection `"cli" => "CLI"` already exists and covers the new path. Required work: 1. present `class CLI < Thor` in `plugins/os-sdlc/lib/os_sdlc/cli.rb` 2. present `class Shell` in `plugins/os-sdlc/lib/os_sdlc/cli/shell.rb` 3. present `class Invocation` in `plugins/os-sdlc/lib/os_sdlc/cli/invocation.rb` 4. present `CommandResult = Data.define` in `plugins/os-sdlc/lib/os_sdlc/command_result.rb` 5. absent `class CLI < Thor` in `plugins/os-sdlc/lib/os_sdlc/crc/cli.rb` 6. absent `Crc::CommandResult` in `plugins/os-sdlc/lib/os_sdlc/**/*.rb` 7. absent `Crc::CLI::Invocation` in `plugins/os-sdlc/lib/os_sdlc/**/*.rb` ## Out of scope Any new Thor command, any change to `Project`, and any change to error text or exit codes. ## Origin Trigger: n/a: design ticket from ruling 126, not a run that showed a fault Improvised this session: none Chain: `Detector::CLI` would inherit from `Crc::CLI` ← the shared Thor base was built inside `Crc` for the crc commands only (ruling 121) ← non-crc commands now move to Thor (owner ruling of 2026-11-10) Session: a48658d5-b566-40ce-8257-ebeabf56f7e1 Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os--claude-worktrees-ticket-1677/a48658d5-b566-40ce-8257-ebeabf56f7e1.jsonl Where: plugins/os-sdlc/lib/os_sdlc/crc/cli.rb (OsSdlc::Crc::CLI), plugins/os-sdlc/lib/os_sdlc/crc/cli/invocation.rb, plugins/os-sdlc/lib/os_sdlc/crc/cli/shell.rb, plugins/os-sdlc/lib/os_sdlc/crc/command_result.rb Root candidate: none found; parent decision ticket #1646 Approved by: predicted ruling 126 (confidence 85), part of the Thor-entry change that Jared ordered on 2026-11-10 ("List the changes we are making. Then implement them."). VERDICT: CREATE REASON: The slice follows from ruling 126, inside the Thor-entry change the owner ordered on 2026-11-10. The move is structural and needed before the other commands can inherit from the base. No open ticket covers the same mechanism.
Author
Owner

Work started on branch ticket-1681 through the fast path (batch fast-batch-24).

Work started on branch ticket-1681 through the fast path (batch fast-batch-24).
Author
Owner

Resolution

Done: The commandless Thor base, its Shell, its Invocation and CommandResult moved from OsSdlc::Crc to OsSdlc (lib/os_sdlc/cli.rb, cli/shell.rb, cli/invocation.rb, command_result.rb). The eleven crc concept CLIs inherit from OsSdlc::CLI. No behavior change.

Evidence: fast-batch-24, commit 34aa6a53d, merged into main. fast-gate PASS; full suite 4066 runs, 0 failures; spec review found nothing missing, added, or wrong; standards review gave two items, both ruled no-change in docs/crc/os-sdlc/fast-batch-24/rulings.tsv.

Follow-ups: none

## Resolution **Done:** The commandless Thor base, its Shell, its Invocation and CommandResult moved from OsSdlc::Crc to OsSdlc (lib/os_sdlc/cli.rb, cli/shell.rb, cli/invocation.rb, command_result.rb). The eleven crc concept CLIs inherit from OsSdlc::CLI. No behavior change. **Evidence:** fast-batch-24, commit 34aa6a53d, merged into main. fast-gate PASS; full suite 4066 runs, 0 failures; spec review found nothing missing, added, or wrong; standards review gave two items, both ruled no-change in docs/crc/os-sdlc/fast-batch-24/rulings.tsv. **Follow-ups:** none <!-- os-backlog kind: resolution -->
jared closed this issue 2026-11-10 21:27:29 +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#1681
No description provided.