CRC wave 4: apply CLI, Checkout, Config, ConfigLocator renames and moves #1024

Closed
opened 2026-10-16 18:24:35 +00:00 by jared · 2 comments
Owner

Problem

Apply 20 ledger rows (rename and move) for CLI, Checkout, Config, ConfigLocator. Each row's path, constant, and test path change as listed in Approach.

Reproduce

n/a: structure-only refactor, no behavior change.

Approach

  1. Required work, in order:
    1. plugins/os-backlog/tests/support/cli_test_helpers.rb -> plugins/os-backlog/tests/support/cli_sandbox.rb
      • constant: CliTestHelpers -> CliSandbox
      • test: no test file
    2. plugins/os-backlog/tests/support/forgejo_cli_helpers.rb -> plugins/os-backlog/tests/support/forgejo_in_process_cli_run.rb
      • constant: ForgejoCliHelpers -> ForgejoInProcessCliRun
      • test: no test file
    3. plugins/os-backlog/tests/support/labels_cli_helpers.rb -> plugins/os-backlog/tests/support/subprocess_cli_run.rb
      • constant: LabelsCliHelpers -> SubprocessCliRun
      • test: no test file
    4. plugins/os-backlog/lib/backlog/bounce.rb -> plugins/os-backlog/lib/backlog/checkout/bounce.rb
      • constant: Backlog::Bounce -> Backlog::Checkout::Bounce
      • test: no test file
    5. plugins/os-backlog/lib/backlog/checkout_result.rb -> plugins/os-backlog/lib/backlog/checkout/result.rb
      • constant: Backlog::CheckoutResult -> Backlog::Checkout::Result
      • test: no test file
    6. plugins/os-backlog/lib/backlog/heading_content_issues.rb -> plugins/os-backlog/lib/backlog/checkout/template_validator/section.rb
      • constant: Backlog::HeadingContentIssues -> Backlog::Checkout::TemplateValidator::Section
      • test: no test file
    7. plugins/os-backlog/lib/backlog/headings_holder.rb -> plugins/os-backlog/lib/backlog/checkout/template_validator/headings.rb
      • constant: Backlog::HeadingsHolder -> Backlog::Checkout::TemplateValidator::Headings
      • test: no test file
    8. plugins/os-backlog/lib/backlog/issue_body.rb -> plugins/os-backlog/lib/backlog/checkout/issue_body.rb
      • constant: Backlog::IssueBody -> Backlog::Checkout::IssueBody
      • test: plugins/os-backlog/tests/issue_body_headings_fence_test.rb -> plugins/os-backlog/tests/checkout/issue_body_headings_fence_test.rb
    9. plugins/os-backlog/lib/backlog/issue_body/fence_stack.rb -> plugins/os-backlog/lib/backlog/checkout/issue_body/fence_stack.rb
      • constant: Backlog::IssueBody::FenceStack -> Backlog::Checkout::IssueBody::FenceStack
      • test: no test file
    10. plugins/os-backlog/lib/backlog/issue_body/lines.rb -> plugins/os-backlog/lib/backlog/checkout/issue_body/heading_parser.rb
    • constant: Backlog::IssueBody::Lines -> Backlog::Checkout::IssueBody::HeadingParser
    • test: no test file
    1. plugins/os-backlog/lib/backlog/retired_test_lines.rb -> plugins/os-backlog/lib/backlog/checkout/template_validator/retired_tests_section.rb
    • constant: Backlog::RetiredTestLines -> Backlog::Checkout::TemplateValidator::RetiredTestsSection
    • test: no test file
    1. plugins/os-backlog/lib/backlog/template_validation_result.rb -> plugins/os-backlog/lib/backlog/checkout/template_validator/result.rb
    • constant: Backlog::TemplateValidationResult -> Backlog::Checkout::TemplateValidator::Result
    • test: no test file
    1. plugins/os-backlog/lib/backlog/template_validator.rb -> plugins/os-backlog/lib/backlog/checkout/template_validator.rb
    • constant: Backlog::TemplateValidator -> Backlog::Checkout::TemplateValidator
    • test: plugins/os-backlog/tests/template_validator_model_sections_test.rb -> plugins/os-backlog/tests/checkout/template_validator_model_sections_test.rb, plugins/os-backlog/tests/template_validator_optional_sections_test.rb -> plugins/os-backlog/tests/checkout/template_validator_optional_sections_test.rb, plugins/os-backlog/tests/template_validator_required_work_check_test.rb -> plugins/os-backlog/tests/checkout/template_validator_required_work_check_test.rb, plugins/os-backlog/tests/template_validator_test.rb -> plugins/os-backlog/tests/checkout/template_validator_test.rb
    1. plugins/os-backlog/lib/backlog/ticket_body_checker.rb -> plugins/os-backlog/lib/backlog/checkout/template_validator/body_validator.rb
    • constant: Backlog::TicketBodyChecker -> Backlog::Checkout::TemplateValidator::BodyValidator
    • test: no test file
    1. plugins/os-backlog/lib/backlog/validation_report.rb -> plugins/os-backlog/lib/backlog/checkout/template_validator/report.rb
    • constant: Backlog::ValidationReport -> Backlog::Checkout::TemplateValidator::Report
    • test: no test file
    1. plugins/os-backlog/tests/support/template_validator_stub_tracker.rb -> plugins/os-backlog/tests/support/template_validator_fake_tracker.rb
    • constant: TemplateValidatorStubTracker -> TemplateValidatorFakeTracker
    • test: no test file
    1. plugins/os-backlog/lib/backlog/config_data.rb -> plugins/os-backlog/lib/backlog/config/entries.rb
    • constant: Backlog::ConfigData -> Backlog::Config::Entries
    • test: no test file
    1. plugins/os-backlog/lib/backlog/config_line.rb -> plugins/os-backlog/lib/backlog/config/line.rb
    • constant: Backlog::ConfigLine -> Backlog::Config::Line
    • test: no test file
    1. plugins/os-backlog/lib/backlog/config_write_command/failed.rb -> plugins/os-backlog/lib/backlog/config_write_command/refused.rb
    • constant: Backlog::ConfigWriteCommand::Failed -> Backlog::ConfigWriteCommand::Refused
    • test: no test file
    1. plugins/os-backlog/lib/backlog/config_locator/dir_context.rb -> plugins/os-backlog/lib/backlog/config_locator/directory_locator.rb
    • constant: Backlog::ConfigLocator::DirContext -> Backlog::ConfigLocator::DirectoryLocator
    • test: no test file
      Before you finish, grep the repository for each old file path and each old constant, not only the constant. Config and docs keep old paths (for example .rubocop.yml, loader collapse lists).
  2. Governing rulings:
    • R7: ConfigWriteCommand holds two jobs: split it (Q28; blind read)
    • R8: Validator, not Checker (Q8)
    • R9: Locator for "finds the path of a file"; Finder and Context go (Q9, Q10)
    • R11: Lines goes: HeadingParser and RetiredTestsSection (Q12)
    • R12: *Section judges one section; HeadingContentIssues becomes TemplateValidator::Section (Q13)
    • R16: Fake is the one prefix for test stand-ins; Stub and Recording go (Q17)
    • R17: New test-support words Sandbox and CliRun; *Chdir and *Assertions stay (Q18, Q36)
    • R18: Result is a verdict; Report is a list of messages (Q19)
    • R19: Config::Entries and the *Line convention (Q20)
    • R22: TemplateValidator and IssueBody go under Checkout (Q23, Q24 part)
    • R29: Objects with callers in one concept nest under it with their name (A2 defect 3; Q37)

Acceptance criteria

  • Every named ledger row is applied, or logged in deviations.md, or reported blocked.
  • ruby plugins/os-backlog/tests/all.rb 0 failures.
  • ruby -e 'require "./plugins/os-backlog/lib/backlog"; Backlog.loader.eager_load' silent.

Owner sketch

Each constant matches its new path; callers follow the new name.

Non-goals

  • No behavior change.
  • No new tests.
  • No deletion of code that has callers.

Origin

  • Session: 6bf383dd-a0e8-4c9b-9e75-286ee89969c3
  • Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os--claude-worktrees-crc-os-adr-2026-10-04/6bf383dd-a0e8-4c9b-9e75-286ee89969c3.jsonl
  • Where: plugins/os-backlog/tests/support/cli_test_helpers.rb, plugins/os-backlog/tests/support/forgejo_cli_helpers.rb, plugins/os-backlog/tests/support/labels_cli_helpers.rb, plugins/os-backlog/lib/backlog/bounce.rb, plugins/os-backlog/lib/backlog/checkout_result.rb, plugins/os-backlog/lib/backlog/heading_content_issues.rb, plugins/os-backlog/lib/backlog/headings_holder.rb, plugins/os-backlog/lib/backlog/issue_body.rb, plugins/os-backlog/lib/backlog/issue_body/fence_stack.rb, plugins/os-backlog/lib/backlog/issue_body/lines.rb, plugins/os-backlog/lib/backlog/retired_test_lines.rb, plugins/os-backlog/lib/backlog/template_validation_result.rb, plugins/os-backlog/lib/backlog/template_validator.rb, plugins/os-backlog/lib/backlog/ticket_body_checker.rb, plugins/os-backlog/lib/backlog/validation_report.rb, plugins/os-backlog/tests/support/template_validator_stub_tracker.rb, plugins/os-backlog/lib/backlog/config_data.rb, plugins/os-backlog/lib/backlog/config_line.rb, plugins/os-backlog/lib/backlog/config_write_command/failed.rb, plugins/os-backlog/lib/backlog/config_locator/dir_context.rb
  • CRC refactor run: docs/crc/os-backlog.
  • Ledger: docs/crc/os-backlog/ledger.tsv
  • Rulings: docs/crc/os-backlog/rulings.md
  • Wave: 4.
## Problem Apply 20 ledger rows (rename and move) for CLI, Checkout, Config, ConfigLocator. Each row's path, constant, and test path change as listed in Approach. ## Reproduce n/a: structure-only refactor, no behavior change. ## Approach 1. Required work, in order: 1. `plugins/os-backlog/tests/support/cli_test_helpers.rb` -> `plugins/os-backlog/tests/support/cli_sandbox.rb` - constant: `CliTestHelpers` -> `CliSandbox` - test: no test file 2. `plugins/os-backlog/tests/support/forgejo_cli_helpers.rb` -> `plugins/os-backlog/tests/support/forgejo_in_process_cli_run.rb` - constant: `ForgejoCliHelpers` -> `ForgejoInProcessCliRun` - test: no test file 3. `plugins/os-backlog/tests/support/labels_cli_helpers.rb` -> `plugins/os-backlog/tests/support/subprocess_cli_run.rb` - constant: `LabelsCliHelpers` -> `SubprocessCliRun` - test: no test file 4. `plugins/os-backlog/lib/backlog/bounce.rb` -> `plugins/os-backlog/lib/backlog/checkout/bounce.rb` - constant: `Backlog::Bounce` -> `Backlog::Checkout::Bounce` - test: no test file 5. `plugins/os-backlog/lib/backlog/checkout_result.rb` -> `plugins/os-backlog/lib/backlog/checkout/result.rb` - constant: `Backlog::CheckoutResult` -> `Backlog::Checkout::Result` - test: no test file 6. `plugins/os-backlog/lib/backlog/heading_content_issues.rb` -> `plugins/os-backlog/lib/backlog/checkout/template_validator/section.rb` - constant: `Backlog::HeadingContentIssues` -> `Backlog::Checkout::TemplateValidator::Section` - test: no test file 7. `plugins/os-backlog/lib/backlog/headings_holder.rb` -> `plugins/os-backlog/lib/backlog/checkout/template_validator/headings.rb` - constant: `Backlog::HeadingsHolder` -> `Backlog::Checkout::TemplateValidator::Headings` - test: no test file 8. `plugins/os-backlog/lib/backlog/issue_body.rb` -> `plugins/os-backlog/lib/backlog/checkout/issue_body.rb` - constant: `Backlog::IssueBody` -> `Backlog::Checkout::IssueBody` - test: `plugins/os-backlog/tests/issue_body_headings_fence_test.rb` -> `plugins/os-backlog/tests/checkout/issue_body_headings_fence_test.rb` 9. `plugins/os-backlog/lib/backlog/issue_body/fence_stack.rb` -> `plugins/os-backlog/lib/backlog/checkout/issue_body/fence_stack.rb` - constant: `Backlog::IssueBody::FenceStack` -> `Backlog::Checkout::IssueBody::FenceStack` - test: no test file 10. `plugins/os-backlog/lib/backlog/issue_body/lines.rb` -> `plugins/os-backlog/lib/backlog/checkout/issue_body/heading_parser.rb` - constant: `Backlog::IssueBody::Lines` -> `Backlog::Checkout::IssueBody::HeadingParser` - test: no test file 11. `plugins/os-backlog/lib/backlog/retired_test_lines.rb` -> `plugins/os-backlog/lib/backlog/checkout/template_validator/retired_tests_section.rb` - constant: `Backlog::RetiredTestLines` -> `Backlog::Checkout::TemplateValidator::RetiredTestsSection` - test: no test file 12. `plugins/os-backlog/lib/backlog/template_validation_result.rb` -> `plugins/os-backlog/lib/backlog/checkout/template_validator/result.rb` - constant: `Backlog::TemplateValidationResult` -> `Backlog::Checkout::TemplateValidator::Result` - test: no test file 13. `plugins/os-backlog/lib/backlog/template_validator.rb` -> `plugins/os-backlog/lib/backlog/checkout/template_validator.rb` - constant: `Backlog::TemplateValidator` -> `Backlog::Checkout::TemplateValidator` - test: `plugins/os-backlog/tests/template_validator_model_sections_test.rb` -> `plugins/os-backlog/tests/checkout/template_validator_model_sections_test.rb`, `plugins/os-backlog/tests/template_validator_optional_sections_test.rb` -> `plugins/os-backlog/tests/checkout/template_validator_optional_sections_test.rb`, `plugins/os-backlog/tests/template_validator_required_work_check_test.rb` -> `plugins/os-backlog/tests/checkout/template_validator_required_work_check_test.rb`, `plugins/os-backlog/tests/template_validator_test.rb` -> `plugins/os-backlog/tests/checkout/template_validator_test.rb` 14. `plugins/os-backlog/lib/backlog/ticket_body_checker.rb` -> `plugins/os-backlog/lib/backlog/checkout/template_validator/body_validator.rb` - constant: `Backlog::TicketBodyChecker` -> `Backlog::Checkout::TemplateValidator::BodyValidator` - test: no test file 15. `plugins/os-backlog/lib/backlog/validation_report.rb` -> `plugins/os-backlog/lib/backlog/checkout/template_validator/report.rb` - constant: `Backlog::ValidationReport` -> `Backlog::Checkout::TemplateValidator::Report` - test: no test file 16. `plugins/os-backlog/tests/support/template_validator_stub_tracker.rb` -> `plugins/os-backlog/tests/support/template_validator_fake_tracker.rb` - constant: `TemplateValidatorStubTracker` -> `TemplateValidatorFakeTracker` - test: no test file 17. `plugins/os-backlog/lib/backlog/config_data.rb` -> `plugins/os-backlog/lib/backlog/config/entries.rb` - constant: `Backlog::ConfigData` -> `Backlog::Config::Entries` - test: no test file 18. `plugins/os-backlog/lib/backlog/config_line.rb` -> `plugins/os-backlog/lib/backlog/config/line.rb` - constant: `Backlog::ConfigLine` -> `Backlog::Config::Line` - test: no test file 19. `plugins/os-backlog/lib/backlog/config_write_command/failed.rb` -> `plugins/os-backlog/lib/backlog/config_write_command/refused.rb` - constant: `Backlog::ConfigWriteCommand::Failed` -> `Backlog::ConfigWriteCommand::Refused` - test: no test file 20. `plugins/os-backlog/lib/backlog/config_locator/dir_context.rb` -> `plugins/os-backlog/lib/backlog/config_locator/directory_locator.rb` - constant: `Backlog::ConfigLocator::DirContext` -> `Backlog::ConfigLocator::DirectoryLocator` - test: no test file Before you finish, grep the repository for each old file path and each old constant, not only the constant. Config and docs keep old paths (for example .rubocop.yml, loader collapse lists). 2. Governing rulings: - R7: `ConfigWriteCommand` holds two jobs: split it (Q28; blind read) - R8: `Validator`, not `Checker` (Q8) - R9: `Locator` for "finds the path of a file"; `Finder` and `Context` go (Q9, Q10) - R11: `Lines` goes: `HeadingParser` and `RetiredTestsSection` (Q12) - R12: `*Section` judges one section; `HeadingContentIssues` becomes `TemplateValidator::Section` (Q13) - R16: `Fake` is the one prefix for test stand-ins; `Stub` and `Recording` go (Q17) - R17: New test-support words `Sandbox` and `CliRun`; `*Chdir` and `*Assertions` stay (Q18, Q36) - R18: `Result` is a verdict; `Report` is a list of messages (Q19) - R19: `Config::Entries` and the `*Line` convention (Q20) - R22: `TemplateValidator` and `IssueBody` go under `Checkout` (Q23, Q24 part) - R29: Objects with callers in one concept nest under it with their name (A2 defect 3; Q37) ## Acceptance criteria - Every named ledger row is applied, or logged in deviations.md, or reported blocked. - `ruby plugins/os-backlog/tests/all.rb` 0 failures. - `ruby -e 'require "./plugins/os-backlog/lib/backlog"; Backlog.loader.eager_load'` silent. ## Owner sketch Each constant matches its new path; callers follow the new name. ## Non-goals - No behavior change. - No new tests. - No deletion of code that has callers. ## Origin - Session: 6bf383dd-a0e8-4c9b-9e75-286ee89969c3 - Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os--claude-worktrees-crc-os-adr-2026-10-04/6bf383dd-a0e8-4c9b-9e75-286ee89969c3.jsonl - Where: plugins/os-backlog/tests/support/cli_test_helpers.rb, plugins/os-backlog/tests/support/forgejo_cli_helpers.rb, plugins/os-backlog/tests/support/labels_cli_helpers.rb, plugins/os-backlog/lib/backlog/bounce.rb, plugins/os-backlog/lib/backlog/checkout_result.rb, plugins/os-backlog/lib/backlog/heading_content_issues.rb, plugins/os-backlog/lib/backlog/headings_holder.rb, plugins/os-backlog/lib/backlog/issue_body.rb, plugins/os-backlog/lib/backlog/issue_body/fence_stack.rb, plugins/os-backlog/lib/backlog/issue_body/lines.rb, plugins/os-backlog/lib/backlog/retired_test_lines.rb, plugins/os-backlog/lib/backlog/template_validation_result.rb, plugins/os-backlog/lib/backlog/template_validator.rb, plugins/os-backlog/lib/backlog/ticket_body_checker.rb, plugins/os-backlog/lib/backlog/validation_report.rb, plugins/os-backlog/tests/support/template_validator_stub_tracker.rb, plugins/os-backlog/lib/backlog/config_data.rb, plugins/os-backlog/lib/backlog/config_line.rb, plugins/os-backlog/lib/backlog/config_write_command/failed.rb, plugins/os-backlog/lib/backlog/config_locator/dir_context.rb - CRC refactor run: docs/crc/os-backlog. - Ledger: docs/crc/os-backlog/ledger.tsv - Rulings: docs/crc/os-backlog/rulings.md - Wave: 4.
Author
Owner

864da48a b17651f5 and test-support commit plus template example commit (see git log); rows applied 20/20; rows deviated 0; rows blocked 0

864da48a b17651f5 and test-support commit plus template example commit (see git log); rows applied 20/20; rows deviated 0; rows blocked 0
Author
Owner

Resolution

Done: Applied 20/20 rows: Config and ConfigLocator, the Checkout cluster (TemplateValidator, IssueBody, RequiredWork), test-support renames, capture template example.

Evidence: 8247f419 864da48a b17651f5 9bdc88cc (ledger 0dea363a); branch crc-os-backlog-2026-10-16 (not merged); os-backlog suite 307 runs, 0 failures; eager load silent; inward lint none

Follow-ups: #1039 (fold Config::Entries into Config, skeptic CREATE)

## Resolution **Done:** Applied 20/20 rows: Config and ConfigLocator, the Checkout cluster (TemplateValidator, IssueBody, RequiredWork), test-support renames, capture template example. **Evidence:** 8247f419 864da48a b17651f5 9bdc88cc (ledger 0dea363a); branch crc-os-backlog-2026-10-16 (not merged); os-backlog suite 307 runs, 0 failures; eager load silent; inward lint none **Follow-ups:** #1039 (fold Config::Entries into Config, skeptic CREATE)
jared closed this issue 2026-10-16 19:25:58 +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#1024
No description provided.