Delete the dead code the CRC census found in os-sdlc #1141
Labels
No labels
P0
P1
P2
P3
bug
category/code-change
category/cross-repo
category/eval-run
category/investigation
category/no-test-target
category/owner-ruling
category/prose-artifact
category/recurring-chore
category/structure
category/umbrella
crc-refactor
create
delete
enhancement
filed-by/agent
filed-by/user
frozen
lint-rule
needs-info
needs-triage
next
plugin/cc-architect
plugin/os
plugin/os-adr
plugin/os-aidd-lint
plugin/os-backlog
plugin/os-context
plugin/os-doc-hygiene
plugin/os-sdlc
plugin/os-vault
project/cc-os
ready-for-agent
ready-for-human
recurring
review
rule-proposal
update
waiting
wayfinder:grilling
wayfinder:map
wayfinder:map
wayfinder:research
wayfinder:task
wayfinder:task
wontfix
worklist/deviations
worklist/lint-rule
worklist/new-implement-build
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
jared/cc-os#1141
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
21 Ruby files have no production caller.
The census grepped lib, bin, hooks, agents, skills, tests, and .rubocop*.yml.
Group 1: lib/os_sdlc/flay_check.rb and flay_check/{finding,snippet,sweep,target}.rb. FlayCheck duplicates CollaboratorPass::Duplication, which calls the Flay gem directly.
Group 2: lib/os_sdlc/lint/autocorrect_prepass.rb and autocorrect_prepass/{capture_runner,pass,residual_output}.rb, with tests/lint/autocorrect_prepass_test.rb, tests/lint/autocorrect_prepass_runner_contract_test.rb, and tests/support/{autocorrect_prepass_scenario,fake_split_capture_runner,fake_two_call_runner}.rb.
Group 3: lib/os_sdlc/git/branch.rb and git/worktree.rb. Only tests/git/branch_test.rb and worktree_test.rb call them. tests/support/fake_git.rb serves only those tests.
Group 4: tests/support/{dispatch_240_fixture,fake_implementation_with_project,flay_fixture_dir,procman_runtime_dir,recording_dispatch_sink,recording_shell,source_line}.rb. The test_helper support loader loads them. Nothing uses them.
Deletion is outside the CRC run's rename, move, and extract scope.
Reproduce
n/a: cleanup.
Approach
Required work:
plugins/os-sdlc/bin/crc-records --target os-sdlc docs/crc/os-sdlcand writegone: <sha> <subject>notes into the deleted rows' evidence cells.Acceptance criteria
crc-recordsexits 0.Origin
VERDICT: CREATE
Work started on branch cleanup-dead-files-adr-paths (worktree).
Resolution
Done: Deleted the 26 files in groups 1-4 (21 named lib/support files plus their 4 tests and fake_git.rb support) after rg/ast-grep showed no lib, test, bin, hook, agent, skill, or rubocop reference; FakeLintShell kept. Fixed crc-records so a gone: row does not resolve through the basename fallback (two deleted constants matched unrelated files). Dropped git/worktree.rb from ADR-0253 affected-paths via adr-new amend. Wrote gone:
e3b083bfnotes into the 22 deleted rows of docs/crc/os-sdlc/ledger.tsv (a6fbfd5a).Evidence: Commits
e3b083bfanda6fbfd5aon branch cleanup-dead-files-adr-paths. Suite: 2103 runs, 4730 assertions, 0 failures, 0 errors (was 2129; deleted tests removed, one new crc-records test). Eager load silent, exit 0. crc-records: stale 0, missing 0, gone 22, stale_adr_paths 0; it still exits 1 only for the 9 false ambiguous rows tracked by open #1072 (HEAD before this work had 10 and also exited 1), so AC4 waits on #1072.Follow-ups: none new; the remaining crc-records exit 1 is already #1072