Stop load-time calls from appearing as steps in a journey #1582

Open
opened 2026-11-06 13:23:05 +00:00 by jared · 0 comments
Owner

Problem

A journey must hold only the steps of its command. The recorder traces every Ruby :call inside a use_case block, and it also traces calls that run while Ruby loads a class. So a journey can show steps that its command never makes, and these steps move between journeys when the test order changes.

Observed

plugins/os-backlog/lib/backlog/issues.rb:58-66 calls route_to_backend 9 times in the class body. These calls run once, at load. After fast-batch-1579, the 9 steps moved from os_backlog_occurrence.c4 to os_backlog_comment.c4 with no change to either command.

Reproduce

plugins/os-sdlc/bin/system-model build plugins/os-backlog
grep -c route_to_backend plugins/os-backlog/design/generated/journeys/os_backlog_comment.c4

Origin

  • Trigger: fast-batch-1579 regeneration, commit b9824613.
  • Improvised this session: none
  • Chain: steps move between journeys ← the first journey to load Backlog::Issues records its class-body calls (lib/backlog/issues.rb:58) ← plugins/os-sdlc/lib/os_sdlc/system_model/recorder/trace.rb:14 traces all :call events and does not skip load time. Ends at DESIGN: recorder/trace.rb.
  • Root candidate: none found; searched trace.rb, recorder, load-time, class body, route_to_backend, journey
  • Where: plugins/os-sdlc/lib/os_sdlc/system_model/recorder/trace.rb
  • Session: 8720f6ad-c6db-428e-977f-7511559fbfbb
  • Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os/8720f6ad-c6db-428e-977f-7511559fbfbb.jsonl

VERDICT: CREATE

## Problem A journey must hold only the steps of its command. The recorder traces every Ruby `:call` inside a `use_case` block, and it also traces calls that run while Ruby loads a class. So a journey can show steps that its command never makes, and these steps move between journeys when the test order changes. ## Observed `plugins/os-backlog/lib/backlog/issues.rb:58-66` calls `route_to_backend` 9 times in the class body. These calls run once, at load. After fast-batch-1579, the 9 steps moved from `os_backlog_occurrence.c4` to `os_backlog_comment.c4` with no change to either command. ## Reproduce ``` plugins/os-sdlc/bin/system-model build plugins/os-backlog grep -c route_to_backend plugins/os-backlog/design/generated/journeys/os_backlog_comment.c4 ``` ## Origin - Trigger: fast-batch-1579 regeneration, commit b9824613. - Improvised this session: none - Chain: steps move between journeys ← the first journey to load `Backlog::Issues` records its class-body calls (`lib/backlog/issues.rb:58`) ← `plugins/os-sdlc/lib/os_sdlc/system_model/recorder/trace.rb:14` traces all `:call` events and does not skip load time. Ends at `DESIGN`: `recorder/trace.rb`. - Root candidate: none found; searched trace.rb, recorder, load-time, class body, route_to_backend, journey - Where: plugins/os-sdlc/lib/os_sdlc/system_model/recorder/trace.rb - Session: 8720f6ad-c6db-428e-977f-7511559fbfbb - Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os/8720f6ad-c6db-428e-977f-7511559fbfbb.jsonl VERDICT: CREATE
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#1582
No description provided.