os-sdlc: a script outside a project points the agent at project setup #838

Open
opened 2026-09-29 21:07:16 +00:00 by jared · 0 comments
Owner

Problem

An os-sdlc script can run in a directory with no .sdlc/project.yaml. When its arguments are valid, it passes the Boot input check, finds no project, and crashes with a Sequel error. The agent then sees a crash and does not know what to do. The message must tell the agent how to fix the problem: run project setup.

Observed

In a directory with no project:

os-sdlc-brief --dispatch-id 1
os-sdlc-brief: harness error: Sequel::Error: No database associated with Sequel::Model: have you called Sequel.connect or Sequel::Model.db= ?

Exit code 3. os-sdlc-gate 1 and os-sdlc-subagent-stop give the same error.

Reproduce

cd $(mktemp -d) && ~/.claude/plugins/os-sdlc/bin/os-sdlc-brief --dispatch-id 1; echo $?

Approach

When ProjectBind finds no root, Boot does not yield to the controller. It prints one message that directs the agent to /os-sdlc:setup-project and exits 3. Hooks keep their exit-0 skip.

Required work: none beyond the acceptance criteria.

Acceptance criteria

  1. Given a directory with no .sdlc/project.yaml, when any script command in Boot::Commands::TABLE runs with valid arguments, then it prints one message that names /os-sdlc:setup-project and exits 3.
  2. Given the same directory, when such a script runs, then no model loads and no .sdlc/ directory is created.
  3. Given the same directory, when a hook runs, then it still exits 0 with its skip message.

Owner sketch

class Boot
  def prepared
end

Origin

  • Trigger: #834 behavior harness, scenarios bare-04, bare-05, bare-08 (commit 72fc9ff8)
  • Improvised this session: none
  • Chain: Sequel crash in a bare dir ← Boot#bound falls back to the unbound dir ← DESIGN (plugins/os-sdlc/lib/os_sdlc/controller/boot.rb, ADR-0248)
  • Root candidate: none
  • Where: plugins/os-sdlc/lib/os_sdlc/controller/boot.rb (Boot#prepared, Boot#bound)
  • Session: 380820d5-6677-444c-a207-9648cba38a64
  • Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os--claude-worktrees-crc-pass-os-sdlc/380820d5-6677-444c-a207-9648cba38a64.jsonl
## Problem An os-sdlc script can run in a directory with no `.sdlc/project.yaml`. When its arguments are valid, it passes the Boot input check, finds no project, and crashes with a Sequel error. The agent then sees a crash and does not know what to do. The message must tell the agent how to fix the problem: run project setup. ## Observed In a directory with no project: ``` os-sdlc-brief --dispatch-id 1 ``` ``` os-sdlc-brief: harness error: Sequel::Error: No database associated with Sequel::Model: have you called Sequel.connect or Sequel::Model.db= ? ``` Exit code 3. `os-sdlc-gate 1` and `os-sdlc-subagent-stop` give the same error. ## Reproduce ``` cd $(mktemp -d) && ~/.claude/plugins/os-sdlc/bin/os-sdlc-brief --dispatch-id 1; echo $? ``` ## Approach When ProjectBind finds no root, Boot does not yield to the controller. It prints one message that directs the agent to `/os-sdlc:setup-project` and exits 3. Hooks keep their exit-0 skip. Required work: none beyond the acceptance criteria. ## Acceptance criteria 1. Given a directory with no `.sdlc/project.yaml`, when any script command in `Boot::Commands::TABLE` runs with valid arguments, then it prints one message that names `/os-sdlc:setup-project` and exits 3. 2. Given the same directory, when such a script runs, then no model loads and no `.sdlc/` directory is created. 3. Given the same directory, when a hook runs, then it still exits 0 with its skip message. ## Owner sketch ```ruby class Boot def prepared end ``` ## Origin - Trigger: #834 behavior harness, scenarios bare-04, bare-05, bare-08 (commit 72fc9ff8) - Improvised this session: none - Chain: Sequel crash in a bare dir ← Boot#bound falls back to the unbound dir ← DESIGN (plugins/os-sdlc/lib/os_sdlc/controller/boot.rb, ADR-0248) - Root candidate: none - Where: plugins/os-sdlc/lib/os_sdlc/controller/boot.rb (Boot#prepared, Boot#bound) - Session: 380820d5-6677-444c-a207-9648cba38a64 - Transcript: /home/jared/.claude/projects/-home-jared-dev-cc-os--claude-worktrees-crc-pass-os-sdlc/380820d5-6677-444c-a207-9648cba38a64.jsonl
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#838
No description provided.