The test asserted the session/cancel request against the log snapshot
returned by the *second* waitForJsonLogMatch, but only the first wait
guaranteed that line — the two log appends are independent, so under
CI load the second snapshot can miss (or tear) the cancel line and the
assertion fails spuriously. Each assertion now checks the snapshot its
own wait resolved on. This flake predates the branch (zero Cursor
files are touched here) but kept failing this PR's Test job.
Co-Authored-By: Claude Fable 5 <[email protected]>
- WorkflowPanel: track a render-visible caught-up flag so the transcript
shows "Loading transcript…" until the first read reaches EOF — an
absence of parsed entries mid-drain means still paging, not that the
agent produced no output
- workflowUi: error rows fall back to resultPreview when the snapshot
carries no error field, so red rows always explain the failure inline
Co-Authored-By: Claude Fable 5 <[email protected]>
Long agent labels were shrink-0 and pushed the model/stats readout off
the clipped right edge. Rows now stack: the label owns the first line
and wraps freely, and model · stats · badges · error text sit on a
muted meta line under it — nothing competes for horizontal space, so
nothing clips regardless of label length. The chevron and status dot
center against the first text line via fixed line-height boxes.
Co-Authored-By: Claude Fable 5 <[email protected]>
The SDK emits tokens/toolCalls on every progress tick (verified against
the bundled runtime), so agent rows now show them live; elapsed time for
a running agent derives from lastProgressAt - startedAt, which advances
tick-by-tick without a client timer. Settled agents keep the reported
total duration.
Agent rows no longer render the routine inline preview text (result and
last-tool snippets) — the expandable transcript owns that detail. Error
text stays inline since it explains a red row at a glance.
Co-Authored-By: Claude Fable 5 <[email protected]>
- Forward the SDK snapshot's per-agent tokens / toolCalls / durationMs
through the contract, adapter normalization, and view model; agent
rows now show model plus "94.2k tok · 47 tools · 7m 03s" (duration
once the agent settles), mirroring the Claude Code TUI
- Rewrite the transcript renderer: only assistant text and tool calls
render (tool rows as "→ Name input-preview"); user turns, tool
results, attachments, and thinking are skipped instead of printing
raw type names ("user attachment attachment")
- Bound transcript memory: retain a 600-line tail with an
"earlier activity trimmed" notice so million-token agent threads
cannot grow client memory unbounded
Co-Authored-By: Claude Fable 5 <[email protected]>
A task.completed for a known workflow task now creates the run when its
task.started has not been applied yet — adopted runs can carry reset
provider sequences across CLI restarts, letting the completion sort
first. The later-applied started only fills metadata and can never
resurrect a terminal status, so derivation correctness no longer
depends on the comparator at all.
Co-Authored-By: Claude Fable 5 <[email protected]>
Real filesystem failures (read-failed / not-found wraps) forward their
underlying error as an optional cause, matching the GitCommandError
convention; pure validation reasons stay cause-less. The paths a cause
can carry are ones the client supplied in the request, so this does not
reintroduce the earlier information-exposure concern.
Co-Authored-By: Claude Fable 5 <[email protected]>
- ClaudeAdapter: dedupe workflow agents/phases by index (last write wins)
before applying entry caps, so repeated slot updates cannot exhaust the
cap and freeze later agents stale; restrict sessionUrl to http(s) so a
hostile tool result cannot smuggle a javascript: href
- workflowUi: guard sessionUrl scheme again at both anchor render sites
(defense in depth for payloads persisted before the adapter filter)
- Ingestion: JSON-encode the (threadId, taskId) tuple in stable workflow
activity ids to remove delimiter-ambiguity collisions
- workflow-logic: order same-timestamp activities by provider sequence
then lifecycle rank so task.completed can never apply before its
task.started
- WorkflowPanel/Card: scope phase and agent row keys by taskId so
switching runs remounts rows instead of leaking expanded transcript
state and cursors across runs
- workflowUi: phase progress counter counts settled (done + error)
agents instead of reporting 0/1 for an errored terminal phase
- client-runtime: readJournal query polls every 4s while mounted so the
Logs tab picks up new results during a live run
- mobile: keep workflow task.completed rows (only per-tick progress is
suppressed) — with no workflow card on mobile it is the only signal a
workflow finished or failed
Co-Authored-By: Claude Fable 5 <[email protected]>
- workflow-logic: settle in-flight agents to "error" when terminalizing
a run whose session died, so a stopped chip never sits above pulsing
"running" agents; drop the dead hasStartedActivity field (snapshot-only
runs render intentionally after history trims)
- ChatView: gate workflow liveness on derivePhase so interrupted
sessions also terminalize runs, matching disconnected-session UX
- WorkflowPanel: fetch the transcript once more when a run leaves
"running" so lines appended after the last poll tick are not lost
- mobile: suppress workflow-owned task.progress/task.completed rows in
the work log, mirroring desktop (mobile has no workflow card yet)
Co-Authored-By: Claude Fable 5 <[email protected]>
- WorkflowInspectionService: re-contain joined leaf files so a symlink
named journal.jsonl / agent-<id>.jsonl cannot escape the projects root
(readScript already did this); add regression tests for both
- Stop serializing raw fs error causes in WorkflowInspectionError
- ProviderCommandReactor: surface stopTask failures as a
provider.task.stop.failed activity instead of a silent log warning
- ProviderService.stopTask: don't resurrect a stopped session via
recovery just to stop a task
- Ingestion: scope stable workflow activity ids by threadId so SDK task
id reuse across threads cannot collide in the projection table
- WorkflowPanel: keep polling transcripts past prior EOF ("complete"
means caught-up, not finished); reuse useCopyToClipboard for the
resume-command button
- workflow-logic: terminalize runs left "running" when the provider
session is gone; add a revision counter so timeline rows re-render on
content changes even when timestamps collide
Co-Authored-By: Claude Fable 5 <[email protected]>
Surface Claude Agent SDK workflow runs (the Workflow orchestration tool)
end to end in the desktop app:
- Contracts: WorkflowProgressEntry schemas, run handles, workflow
inspection RPCs, thread.task.stop command + task-stop-requested event
- ClaudeAdapter: normalize the SDK's undocumented workflow_progress
snapshot (size-capped, tolerant), forward workflow identity on task
events, emit task.workflowMeta from Workflow tool results, stopTask
- Ingestion: upsert workflow snapshots under a stable per-task activity
id so projections and reconnect payloads stay one row per run
- WorkflowInspectionService: path-validated, size-capped reads of the
run's script, journal, and per-agent transcripts (realpath containment
under ~/.claude/projects)
- Web: WorkflowRunCard inline in the chat timeline, a workflow right-
panel surface with Run/Script/Logs tabs, cursor-paged transcript
polling, stop + resume affordances; remote runs link to their cloud
session
Co-Authored-By: Claude Fable 5 <[email protected]>