Every view listing runs or approvals polled on a timer: the home page made
four requests every five seconds per open tab, two of them the same run list,
and the needs-attention card asked for 200 runs to render five.
A run or an approval request moving is now published on the hub and framed on
the dashboard stream, so those views re-read on the change. A reconnect still
re-reads everything, and the hub drops a reader that falls behind, which ends
its stream and reconnects it.
Cancelling a run moved it and the runs it called to cancelled and wrote nothing
to either trail, so a stopped run could not say when it stopped or who asked.
The stop now returns the runs it stopped and records one cancel entry on each,
in the same transaction, naming the principal that asked. The entry is a step
named cancel with the caller's identity, so the run detail shows it with the
rest of the trail.
A disabled workflow is never started by a trigger, another workflow or a
person. Delete is refused while a trigger, another workflow or a run in
progress names it. A parked or ended run restarts from a step.
POST /api/runs/{id}/cancel now reaches Engine.Cancel, which cancels the
run and the runs it started with workflow.call, and returns the run.
Cancelling a run that has already ended is refused with a 409, and a run
from another organisation is not found. The run page shows a Cancel
action for a run that has not ended.
Add workflow.finish (completed, parked, waiting_approval, declined). A failed
step parks the run unless it continues on failure, and a parked run retries
from a top-level step, replaying the earlier steps' recorded results. Adds the
retry-run operation and a Retry button on the run page.
Two faults stopped an investigation from finishing on staging.
The runtime role was granted DML on every table but nothing on sequences, so
the first table keyed by a serial (deliveries.messages) failed its insert with
"permission denied for sequence messages_seq_seq", failing the run at its
notification step.
A run that failed has no result, and a step with no output is recorded as NULL;
the rows were read straight into jsontext.Value, which can't hold NULL, so the
trail API answered 500 for exactly the runs and steps that needed reading. The
reads coalesce to JSON null instead.
Verified on staging after deploying: the same run's trail reads back.
GET /api/runs/{id} assembles a run's trail from rows already kept: the event
and trigger that started it, each workflow step, and each model and tool call
from the agent's journal. Investigations end by notifying their findings on
the composer, whose messages are read from a cursor with a live stream that
only says when to read. The binary serves its own SPA entry, archie.html,
calling only the new API. The investigate prompt now treats the event as a
claim to check against what it measures.