Behavior-verifier misses changes outside code_path #629

Closed
opened 2026-09-22 21:47:24 +00:00 by jared · 3 comments
Owner

Problem

Found in /os-sdlc:implement 627, implementation 12, dispatch 150 (behavior-verifier). The verifier's only evidence is the code_changes brief fact.

Observed

code_changes comes from Model::Project::Changes#code_diff (plugins/os-sdlc/lib/os_sdlc/model/project/changes.rb). This method diffs only changed paths inside the target's code_path (plugins/os-sdlc/lib for target os-sdlc). #627 cases 6 and 7 edit plugins/os-sdlc/agents/wiring.md and .claude/settings.json. Both files were outside code_path. Both edits were present in the working tree, but the verifier did not see them and failed the increment as missing.

code_changes has no change to plugins/os-sdlc/agents/wiring.md
The programmer handoff says both edits exist, and the session start status lists both files as modified. If so, code_changes omits files outside lib/ and the diff scope needs correction.

The fail routed to test-writer (bound 2, progress_reset). test-writer's tests for cases 6 and 7 already passed, so the run escalated with reason unexpected_pass:test-writer/diff-test. The ticket was hand-finished.

Reproduce

Run /os-sdlc:implement on any ticket whose ## Cases include a file outside the target's code_path and test_path.

Expected

The behavior-verifier sees every changed file the increment produced, including files outside code_path and test_path.

Illustration

# illustration, not spec
# poodr-ticket-implementation.yaml, behavior-verifier node:
enrich:
  - code_changes
  - changed_files_outside_scope   # paths + diff, per ADR-0204 (never cut)

Origin

  • Trigger: escalation on implementation 12, dispatch 150 (behavior-verifier)
  • Improvised this session: none
  • Chain: verifier reports missing files ← code_changes scoped to code_path ← Model::Project::Changes#code_diff diffs only code_path ← DESIGN (evidence scope in Changes#code_paths)
  • Root candidate: this ticket
  • Where: plugins/os-sdlc/lib/os_sdlc/pipeline/brief_facts.rb#code_changes, plugins/os-sdlc/lib/os_sdlc/model/project/changes.rb, plugins/os-sdlc/maps/poodr-ticket-implementation.yaml (behavior-verifier node)
  • Session: 94320dd4-8ab4-49a8-ad82-a46504401428
  • Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os/94320dd4-8ab4-49a8-ad82-a46504401428.jsonl

Skeptic verdict: CREATE — genuine defect in a real /os-sdlc:implement run (dispatch 150, behavior-verifier); code_changes evidence is scoped to code_path and silently drops in-scope case files outside it, causing false "missing" verdicts and wasted escalation/hand-finish cycles; Origin chain traces to a DESIGN root (Changes#code_diff scope), with this ticket as that root.

## Problem Found in /os-sdlc:implement 627, implementation 12, dispatch 150 (behavior-verifier). The verifier's only evidence is the `code_changes` brief fact. ## Observed `code_changes` comes from `Model::Project::Changes#code_diff` (plugins/os-sdlc/lib/os_sdlc/model/project/changes.rb). This method diffs only changed paths inside the target's `code_path` (plugins/os-sdlc/lib for target os-sdlc). #627 cases 6 and 7 edit plugins/os-sdlc/agents/wiring.md and .claude/settings.json. Both files were outside `code_path`. Both edits were present in the working tree, but the verifier did not see them and failed the increment as missing. ``` code_changes has no change to plugins/os-sdlc/agents/wiring.md ``` ``` The programmer handoff says both edits exist, and the session start status lists both files as modified. If so, code_changes omits files outside lib/ and the diff scope needs correction. ``` The fail routed to test-writer (bound 2, progress_reset). test-writer's tests for cases 6 and 7 already passed, so the run escalated with reason `unexpected_pass:test-writer/diff-test`. The ticket was hand-finished. ## Reproduce Run /os-sdlc:implement on any ticket whose `## Cases` include a file outside the target's `code_path` and `test_path`. ## Expected The behavior-verifier sees every changed file the increment produced, including files outside `code_path` and `test_path`. ## Illustration ```ruby # illustration, not spec # poodr-ticket-implementation.yaml, behavior-verifier node: enrich: - code_changes - changed_files_outside_scope # paths + diff, per ADR-0204 (never cut) ``` ## Origin - Trigger: escalation on implementation 12, dispatch 150 (behavior-verifier) - Improvised this session: none - Chain: verifier reports missing files ← code_changes scoped to code_path ← Model::Project::Changes#code_diff diffs only code_path ← DESIGN (evidence scope in Changes#code_paths) - Root candidate: this ticket - Where: plugins/os-sdlc/lib/os_sdlc/pipeline/brief_facts.rb#code_changes, plugins/os-sdlc/lib/os_sdlc/model/project/changes.rb, plugins/os-sdlc/maps/poodr-ticket-implementation.yaml (behavior-verifier node) - Session: 94320dd4-8ab4-49a8-ad82-a46504401428 - Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os/94320dd4-8ab4-49a8-ad82-a46504401428.jsonl Skeptic verdict: CREATE — genuine defect in a real /os-sdlc:implement run (dispatch 150, behavior-verifier); code_changes evidence is scoped to code_path and silently drops in-scope case files outside it, causing false "missing" verdicts and wasted escalation/hand-finish cycles; Origin chain traces to a DESIGN root (Changes#code_diff scope), with this ticket as that root.
Author
Owner

Absorbed into #645: the fix moves from verifier-only to an explicit target root for every role and the diff-test gate.

Absorbed into #645: the fix moves from verifier-only to an explicit target root for every role and the diff-test gate.
Author
Owner

#645 (main 1725c5bc, ADR-0208) fixes the Ruby part: bin/ and other Ruby files under the target root_path now reach code_changes and the diff-test gate. This ticket stays open for the remaining part: non-Ruby files under root_path (agent charters .md, settings.json; #627 impl 12 wiring.md) are still not in behavior-verifier code_changes. Ticket-skeptic verdict 2026-09-23: merge that follow-up here rather than file a new ticket.

#645 (main 1725c5bc, ADR-0208) fixes the Ruby part: bin/ and other Ruby files under the target root_path now reach code_changes and the diff-test gate. This ticket stays open for the remaining part: non-Ruby files under root_path (agent charters .md, settings.json; #627 impl 12 wiring.md) are still not in behavior-verifier code_changes. Ticket-skeptic verdict 2026-09-23: merge that follow-up here rather than file a new ticket.
Author
Owner

Resolution

Done: Absorbed by #655: every file under the target, including non-Ruby files, enters code_changes.

Evidence: #655 Acceptance criteria cover agents/wiring.md in code_changes.

Follow-ups: none

## Resolution **Done:** Absorbed by #655: every file under the target, including non-Ruby files, enters code_changes. **Evidence:** #655 Acceptance criteria cover agents/wiring.md in code_changes. **Follow-ups:** none
jared closed this issue 2026-09-23 21:37:32 +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#629
No description provided.