Shrink the inward-dependency baseline and re-layer IssueSource, Map, Records #741

Closed
opened 2026-09-26 12:38:16 +00:00 by jared · 5 comments
Owner

Problem

The inward-dependency rule now lives at plugins/os-sdlc/lib/os_sdlc/lint/inward_dependencies.rb and plugins/os-sdlc/bin/lint-inward-dependencies, unit-tested by plugins/os-sdlc/tests/lint/inward_dependencies_test.rb. Running the bin script against current main reports 62 outward references. The tool carries no KNOWN_VIOLATIONS baseline and is not wired into the suite as a gate — nothing fails when the count changes.

Of the three concepts named in the original ticket, two are resolved: Map moved fully under model/ (ADR-0228). Records no longer exists as a class or constant anywhere in the lib tree — dissolved during the CRC pass. IssueSource remains split across two role directories:

  • plugins/os-sdlc/lib/os_sdlc/adapter/issue_source/ticket_fetcher.rb
  • plugins/os-sdlc/lib/os_sdlc/adapter/issue_source/github.rb
  • plugins/os-sdlc/lib/os_sdlc/adapter/issue_source/shell.rb
  • plugins/os-sdlc/lib/os_sdlc/adapter/issue_source/forgejo.rb
  • plugins/os-sdlc/lib/os_sdlc/adapter/issue_source/tracker_resolver.rb
  • plugins/os-sdlc/lib/os_sdlc/command/issue_source.rb

Every adapter/issue_source/* file depends on command/issue_source.rb, which is an inward (command -> adapter direction crossing) reference under ADR-0222's role-layer ordering.

Approach

Decide IssueSource's correct layer from the 62-reference report, move it, then make the lint tool an enforced gate with a baseline that only tolerates ADR-allowed lines.

Required work:

  1. Decide IssueSource's layer by evidence from the current 62-reference report and move lib/os_sdlc/command/issue_source.rb accordingly.
  2. Add plugins/os-sdlc/bin/lint-inward-dependencies as a suite gate backed by a baseline file listing each remaining reference with either an allowing ADR citation or none.
  3. Shrink the baseline to zero remaining lines, or leave only lines each citing an ADR that permits the crossing.

Acceptance criteria

  1. Given the inward-dependency gate, when run against main, then every reported outward reference is either absent or present in the baseline with a citing ADR.
  2. Given the full suite, when run, then it passes with the new gate included.
  3. Given ruby plugins/os-sdlc/bin/lint-inward-dependencies, when run, then no IssueSource line appears in its output.

Reproduce

ruby plugins/os-sdlc/bin/lint-inward-dependencies

Current output: 62 outward references, no gate enforcing them.

Origin

  • Session: e677319c-fe8c-46dc-a275-07d89d4faf97
  • Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os--claude-worktrees-crc-pass-os-sdlc/e677319c-fe8c-46dc-a275-07d89d4faf97.jsonl
  • Where: plugins/os-sdlc/tests/inward_dependency_test.rb, plugins/os-sdlc/lib/os_sdlc/command/issue_source.rb, pipeline/map.rb, query/records.rb
  • Source: #737 move, ADR-0222, 2026-09-26
  • Re-spec: 2026-09-28 session 95e8b17c, after CRC pass ADR-0237; Map resolved by ADR-0228, Records dissolved
## Problem The inward-dependency rule now lives at plugins/os-sdlc/lib/os_sdlc/lint/inward_dependencies.rb and plugins/os-sdlc/bin/lint-inward-dependencies, unit-tested by plugins/os-sdlc/tests/lint/inward_dependencies_test.rb. Running the bin script against current main reports 62 outward references. The tool carries no KNOWN_VIOLATIONS baseline and is not wired into the suite as a gate — nothing fails when the count changes. Of the three concepts named in the original ticket, two are resolved: Map moved fully under model/ (ADR-0228). Records no longer exists as a class or constant anywhere in the lib tree — dissolved during the CRC pass. IssueSource remains split across two role directories: - plugins/os-sdlc/lib/os_sdlc/adapter/issue_source/ticket_fetcher.rb - plugins/os-sdlc/lib/os_sdlc/adapter/issue_source/github.rb - plugins/os-sdlc/lib/os_sdlc/adapter/issue_source/shell.rb - plugins/os-sdlc/lib/os_sdlc/adapter/issue_source/forgejo.rb - plugins/os-sdlc/lib/os_sdlc/adapter/issue_source/tracker_resolver.rb - plugins/os-sdlc/lib/os_sdlc/command/issue_source.rb Every adapter/issue_source/* file depends on command/issue_source.rb, which is an inward (command -> adapter direction crossing) reference under ADR-0222's role-layer ordering. ## Approach Decide IssueSource's correct layer from the 62-reference report, move it, then make the lint tool an enforced gate with a baseline that only tolerates ADR-allowed lines. Required work: 1. Decide IssueSource's layer by evidence from the current 62-reference report and move lib/os_sdlc/command/issue_source.rb accordingly. 2. Add plugins/os-sdlc/bin/lint-inward-dependencies as a suite gate backed by a baseline file listing each remaining reference with either an allowing ADR citation or none. 3. Shrink the baseline to zero remaining lines, or leave only lines each citing an ADR that permits the crossing. ## Acceptance criteria 1. Given the inward-dependency gate, when run against main, then every reported outward reference is either absent or present in the baseline with a citing ADR. 2. Given the full suite, when run, then it passes with the new gate included. 3. Given `ruby plugins/os-sdlc/bin/lint-inward-dependencies`, when run, then no IssueSource line appears in its output. ## Reproduce ruby plugins/os-sdlc/bin/lint-inward-dependencies Current output: 62 outward references, no gate enforcing them. ## Origin - Session: e677319c-fe8c-46dc-a275-07d89d4faf97 - Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os--claude-worktrees-crc-pass-os-sdlc/e677319c-fe8c-46dc-a275-07d89d4faf97.jsonl - Where: plugins/os-sdlc/tests/inward_dependency_test.rb, plugins/os-sdlc/lib/os_sdlc/command/issue_source.rb, pipeline/map.rb, query/records.rb - Source: #737 move, ADR-0222, 2026-09-26 - Re-spec: 2026-09-28 session 95e8b17c, after CRC pass ADR-0237; Map resolved by ADR-0228, Records dissolved
Author
Owner

Scanner now resolves nested role objects to their own file's role via OsSdlc.loader.all_expected_cpaths; baseline re-recorded at 75 (13 real model/adapter -> Map/Project/Probe/FlayCheck edges surfaced, 10 first-segment false positives dropped). Commit c78dd226.

Scanner now resolves nested role objects to their own file's role via OsSdlc.loader.all_expected_cpaths; baseline re-recorded at 75 (13 real model/adapter -> Map/Project/Probe/FlayCheck edges surfaced, 10 first-segment false positives dropped). Commit c78dd226.
Author
Owner

Filed #744, #745, #746 as children of this baseline-shrinking work: #744 fixes inward_dependency_test's comment/string false positives (KNOWN_VIOLATIONS re-record), #745 adds the analogous guard for concepts with a missing or misplaced namespace root under ADR-0222 item 3 (KNOWN_ROOTLESS baseline), and #746 moves RunnerCLI out of pipeline/ into cli/, which shrinks that same baseline by 2 entries.

Filed #744, #745, #746 as children of this baseline-shrinking work: #744 fixes inward_dependency_test's comment/string false positives (KNOWN_VIOLATIONS re-record), #745 adds the analogous guard for concepts with a missing or misplaced namespace root under ADR-0222 item 3 (KNOWN_ROOTLESS baseline), and #746 moves RunnerCLI out of pipeline/ into cli/, which shrinks that same baseline by 2 entries.
Author
Owner

Re-spec review, 2026-09-28: ticket's evidence is stale and the goal is largely already resolved or no longer applicable. Recommend CLOSE, not implement.

Findings against current main:

  • tests/inward_dependency_test.rb (cited path) no longer exists. The rule now lives at plugins/os-sdlc/lib/os_sdlc/lint/inward_dependencies.rb + bin/lint-inward-dependencies, tested by plugins/os-sdlc/tests/lint/inward_dependencies_test.rb. That test file only unit-tests the InwardDependencies engine (constant resolution, outward-reference detection) — it carries no KNOWN_VIOLATIONS baseline and is not a gate. Nothing enforces a violation count today.
  • Running ruby bin/lint-inward-dependencies on current main returns 62 outward references (not the ticket's cited 72), none tracked as a baseline anywhere.
  • Map: fully resolved. ADR-0228 explicitly moved Map and its validator tree under model/. grep -rn "class Map\b" plugins/os-sdlc/lib shows every Map file under lib/os_sdlc/model/map/ (plus one adapter/map/loader.rb helper and one parser/map/* file, both legitimate role objects, not the core class).
  • Records: does not exist. No file anywhere under plugins/os-sdlc/lib defines class Records or references OsSdlc::Records. The concept named in the ticket was dissolved/renamed during the CRC pass (#779-#787, ADR-0222/0235/0236/0237); there is nothing left to re-layer.
  • IssueSource: still spans two roles — lib/os_sdlc/adapter/issue_source/*.rb (5 files) and lib/os_sdlc/command/issue_source.rb (1 file) — this part of the original complaint is the only one still live.

Given the baseline mechanism the ticket is built around doesn't exist, two of its three named concepts are already resolved or gone, and the count itself is wrong, the ticket cannot be re-specced against current evidence without functionally rewriting it as a new ticket. Recommend closing #741 and, if IssueSource's split still matters, filing a fresh, narrowly-scoped ticket against the current lint tool and the 62-reference figure.

Session 95e8b17c.

Re-spec review, 2026-09-28: ticket's evidence is stale and the goal is largely already resolved or no longer applicable. Recommend CLOSE, not implement. Findings against current main: - tests/inward_dependency_test.rb (cited path) no longer exists. The rule now lives at plugins/os-sdlc/lib/os_sdlc/lint/inward_dependencies.rb + bin/lint-inward-dependencies, tested by plugins/os-sdlc/tests/lint/inward_dependencies_test.rb. That test file only unit-tests the InwardDependencies engine (constant resolution, outward-reference detection) — it carries no KNOWN_VIOLATIONS baseline and is not a gate. Nothing enforces a violation count today. - Running `ruby bin/lint-inward-dependencies` on current main returns 62 outward references (not the ticket's cited 72), none tracked as a baseline anywhere. - Map: fully resolved. ADR-0228 explicitly moved Map and its validator tree under model/. `grep -rn "class Map\b" plugins/os-sdlc/lib` shows every Map file under lib/os_sdlc/model/map/ (plus one adapter/map/loader.rb helper and one parser/map/* file, both legitimate role objects, not the core class). - Records: does not exist. No file anywhere under plugins/os-sdlc/lib defines `class Records` or references `OsSdlc::Records`. The concept named in the ticket was dissolved/renamed during the CRC pass (#779-#787, ADR-0222/0235/0236/0237); there is nothing left to re-layer. - IssueSource: still spans two roles — lib/os_sdlc/adapter/issue_source/*.rb (5 files) and lib/os_sdlc/command/issue_source.rb (1 file) — this part of the original complaint is the only one still live. Given the baseline mechanism the ticket is built around doesn't exist, two of its three named concepts are already resolved or gone, and the count itself is wrong, the ticket cannot be re-specced against current evidence without functionally rewriting it as a new ticket. Recommend closing #741 and, if IssueSource's split still matters, filing a fresh, narrowly-scoped ticket against the current lint tool and the 62-reference figure. Session 95e8b17c.
Author
Owner

Re-specced 2026-09-28 (session 95e8b17c). The ticket body has been rewritten against current main. My earlier comment recommending closure is withdrawn: two parts of the original complaint are still live — IssueSource is split between adapter/issue_source/ (5 files) and command/issue_source.rb, and plugins/os-sdlc/bin/lint-inward-dependencies currently reports 62 outward references with no baseline and no suite gate. New Required work: (1) decide and move IssueSource's layer, (2) wire the lint bin into the suite as a gate backed by a baseline file, (3) shrink that baseline to zero or ADR-allowed lines. Map (ADR-0228) and Records (dissolved) are noted as already resolved in the Problem section.

Re-specced 2026-09-28 (session 95e8b17c). The ticket body has been rewritten against current main. My earlier comment recommending closure is withdrawn: two parts of the original complaint are still live — IssueSource is split between adapter/issue_source/ (5 files) and command/issue_source.rb, and plugins/os-sdlc/bin/lint-inward-dependencies currently reports 62 outward references with no baseline and no suite gate. New Required work: (1) decide and move IssueSource's layer, (2) wire the lint bin into the suite as a gate backed by a baseline file, (3) shrink that baseline to zero or ADR-allowed lines. Map (ADR-0228) and Records (dissolved) are noted as already resolved in the Problem section.
Author
Owner

Resolution

Done: folded into #748 per ruling (d) 2026-10-16

Evidence: bin/lint-inward-dependencies still reports unmapped lines; Phase 7 of docs/crc/PLAN.md deletes the ratchet (#748)

Follow-ups: folded into #748

## Resolution **Done:** folded into #748 per ruling (d) 2026-10-16 **Evidence:** bin/lint-inward-dependencies still reports unmapped lines; Phase 7 of docs/crc/PLAN.md deletes the ratchet (#748) **Follow-ups:** folded into #748
jared closed this issue 2026-10-16 16:51:21 +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#741
No description provided.