fabro/lib/apps/fabro-server/tests/it/scenario
Bryan Helmkamp 968c46d69b
Settle an in-process run at Petri's finish, not at its terminal record
The in-process Petri path settled the run's in-memory managed run once
Fabro's terminal lifecycle record was stored, after the engine returned.
GET /runs/{id} reads the stored summary, which the projector ends at
Petri's own `run.finished` record, a moment earlier, so a delete issued
the moment the run read as ended could reach the delete precheck, which
prefers the managed run, while it still said running, and was refused
with 409 "cannot remove active run". Against the real engine the window
hit eight times in thirty.

The worker path settles its run at the worker's records endpoint, ahead
of the store (#888). The in-process run now settles at the same record
through the run store it executes over: a store whose coordinator
appends settle the managed run at the `run.finished` record before the
record reaches the store and the projector's signal, with the same
finish mapping and settle the worker path uses. The settle is in memory
only. The terminal lifecycle record stored once the engine returns
refines the status and error and ends the run's live state as before,
and stays the settle of a run that ends without an engine finish.

The prune scenario no longer waits for the managed run to settle before
its delete: the wait guarded only this window.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-21 12:08:48 -04:00
..
archive.rs Fix what the gates found after the removal sweep 2026-09-19 10:15:15 -04:00
dry_run.rs Drop redundant create tests and reuse the production client in fixtures 2026-09-13 09:16:31 -06:00
lifecycle.rs Delete fabro-core and the engine half of fabro-workflow 2026-09-18 10:44:41 -04:00
mod.rs Serve a Petri run's events as one stream with a stream_seq cursor 2026-09-18 00:47:26 -04:00
petri.rs Settle an in-process run at Petri's finish, not at its terminal record 2026-09-21 12:08:48 -04:00
petri_stream.rs Project a Petri run's sandbox instance from its scope records 2026-09-18 15:57:12 -04:00
run_completion.rs Delete fabro-core and the engine half of fabro-workflow 2026-09-18 10:44:41 -04:00
sse.rs Delete fabro-core and the engine half of fabro-workflow 2026-09-18 10:44:41 -04:00
usage.rs Carry usage as lithos-llm's Usage and rename billing to usage 2026-09-14 12:31:34 -06:00