Skip to content

feat(sdlc): resume pending work and recover from the monitor - #41

Merged
mingchuno merged 1 commit into
mainfrom
user-frictions-3-daily
Oct 22, 2026
Merged

mingchuno merged 1 commit into
mainfrom
user-frictions-3-daily

Conversation

@mingchuno

Copy link
Copy Markdown
Owner

Phase 3 of 3 (stacked on #40): the daily loop. The human no longer runs work … commands, and the skill spends fewer tokens per step.

Summary

 /start-work
+  (no task) → work list --brief → one line per Work Item + next action → "which to resume?"

 work <cmd>
-  --project ID required                 → inferred from the checkout, like doctor
-  --file /tmp/contract.json only        → also --file - (stdin)
-  pretty JSON (2-space)                 → compact JSON
-  propose … && inspect && publish …     → propose … --publish
+  list --brief → [{id, title, source, track, state, approvalComment?}]

 escalation recovery
-  human runs: work submit ID --revision R --recover
+  WorkItemView.recoverable = ready && project blocked
+  TUI: r → confirm   ·   web: "Resubmit after recovery" → POST /api/work-items/:id/resubmit
+    workOperator.resubmit → admitWork(recovery: assertCheckoutReleased)

The skill references (SKILL.md, work-api.md, delegated.md) and the SDLC guide now send humans to the monitors for approval and recovery. The CLI equivalents are kept as notes.

Evidence

  • tests/work-cli.test.ts:
    • from the checkout, without --project: propose --publish rewrites the issue section and prints one line of JSON
    • list --brief returns exactly {id, title, source, track, state}
    • classify --file - reads the contract from stdin
  • tests/work-console.test.ts:
    • operator.resubmit refuses a dirty checkout, then admits attempt 2 and clears the block
    • an operator built without stateDirectory refuses with "unavailable"
    • the web route returns 409 with the policy reason, and 400 for a missing revision
  • tests/work-console.test.tsx: in the TUI, r → confirm → resubmits the inspected revision.
  • pnpm verify: 404 tests, 401 passed, 0 failed (3 live-provider tests skipped).

Merge Danger

Door: two-way

Blast Radius: work CLI

  • Work command output is now compact JSON; scripts that parse it still work. Without --project, running outside a configured checkout fails and asks for --project.
  • Resubmission from the monitor clears a project block. It runs the same safety checks as submit --recover.

🤖 Generated with Claude Code

@mingchuno
mingchuno force-pushed the user-frictions-3-daily branch from ec0cece to 536f0c2 Compare October 22, 2026 09:01
@mingchuno mingchuno changed the title feat(sdlc): Resume pending work and recover from the monitor feat(sdlc): resume pending work and recover from the monitor Oct 22, 2026
@mingchuno
mingchuno force-pushed the user-frictions-3-daily branch from 536f0c2 to 3fe40ce Compare October 22, 2026 09:14
@mingchuno
mingchuno added this pull request to stack #42 October 22, 2026 09:37
@mingchuno
mingchuno force-pushed the user-frictions-3-daily branch from 3fe40ce to 65f8b2e Compare October 22, 2026 09:40
Base automatically changed from user-frictions-2-approval to main October 22, 2026 09:41
- start-work without a task lists pending Work Items via
  `work list --brief` and asks which to resume
- work commands infer the project from the current directory, read
  contracts from stdin with `--file -`, print compact JSON, and
  `propose --publish` republishes in one step
- the operator marks ready work in an escalation-blocked project as
  recoverable; `r` in the terminal monitor and "Resubmit after recovery"
  in the web monitor admit it after the checkout safety checks
- the SDLC guide approves and recovers through the monitors, with CLI
  equivalents noted

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@mingchuno
mingchuno force-pushed the user-frictions-3-daily branch from 65f8b2e to c649199 Compare October 22, 2026 09:41
@mingchuno
mingchuno merged commit 670d78b into main Oct 22, 2026
@mingchuno
mingchuno deleted the user-frictions-3-daily branch October 22, 2026 09:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant