fabro/lib/foundation
Bryan Helmkamp 3f721dd032
Consume the sandbox driver's events directly in the workflow
Fabro-sandbox carried its own SandboxEvent enum and a callback for it.
The run sandbox wrapped every lifecycle call to emit a start, completed,
or failed variant with its own clock, and re-described the driver's
create-time progress as snapshot events through an observer that lived
next to the run sandbox. The workflow then converted that enum to the
wire. The driver already reports every operation it performs, so the
enum was a second, hand-maintained copy of that stream.

The workflow now observes the driver's events directly. A run's sandbox
is created or attached with a driver EventContext whose observer is the
new SandboxEventBridge in the workflow's event module. The bridge turns
the driver's start, stop, and delete operations, its image pull inside a
create, and its snapshot builds into the workflow's SandboxLifecycle
events, stamping fabro's provider name so the run keeps recording
`local` rather than the driver's `host`. The pipeline emits the
initializing, ready, and failed events itself around bringing the sandbox
up, since that composite step — create, activate, prepare the workspace
— is the pipeline's, not the driver's. Fabro-sandbox emits no events of
its own any more; the run sandbox gained console_url for the ready
event, and a local sandbox can be created with an event context.

The wire keeps every name the CLI reads. Two families go: the cleanup
events, which only the server's manifest validation could have produced
and it passed no callback, and the git clone events, which nothing read
and whose facts the sandbox.initialized event and tracing already carry.
The ready event drops the cpu and memory fields no provider ever
populated. Daytona snapshot events now come from the driver's ensure
call, so a snapshot that already exists and is active reports nothing
rather than a creating-and-ready pair that did no work.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-10 00:37:42 -06:00
..
build-support refactor: organize crates into three layers 2026-07-23 17:59:34 -04:00
fabro-api Open sandbox provider identity to plugin kinds 2026-09-09 15:17:32 -06:00
fabro-auth fix(model): prefer MOONSHOT_API_KEY 2026-07-31 09:14:58 -04:00
fabro-client Open sandbox provider identity to plugin kinds 2026-09-09 15:17:32 -06:00
fabro-config Name plugins by their configured kind and drop out-of-process bundled kinds 2026-09-09 20:13:50 -06:00
fabro-core Harden succeed failure policy routing 2026-08-26 09:13:04 -04:00
fabro-db Run plugin providers end to end and gate them in CI 2026-09-09 19:54:57 -06:00
fabro-dev Harden release push recovery 2026-08-21 19:28:55 -04:00
fabro-http refactor: organize crates into three layers 2026-07-23 17:59:34 -04:00
fabro-macros refactor: organize crates into three layers 2026-07-23 17:59:34 -04:00
fabro-model refactor(model): simplify model test plumbing 2026-08-25 14:49:34 -04:00
fabro-oauth refactor: organize crates into three layers 2026-07-23 17:59:34 -04:00
fabro-options-metadata refactor: organize crates into three layers 2026-07-23 17:59:34 -04:00
fabro-proc refactor: organize crates into three layers 2026-07-23 17:59:34 -04:00
fabro-redact Address run spec persistence review findings 2026-08-20 20:35:52 -04:00
fabro-static feat(search): add Venice backend for web_search 2026-08-21 12:31:03 -07:00
fabro-telemetry refactor: organize crates into three layers 2026-07-23 17:59:34 -04:00
fabro-template Simplify model stylesheet template plumbing 2026-08-25 18:54:06 -04:00
fabro-test Merge remote-tracking branch 'origin/main' into fix/redaction-corrupts-executable-spec 2026-08-20 20:42:20 -04:00
fabro-types Consume the sandbox driver's events directly in the workflow 2026-09-10 00:37:42 -06:00
fabro-util Neutralize runtime for_each labels before display 2026-07-28 19:52:59 -04:00
fabro-vault refactor: organize crates into three layers 2026-07-23 17:59:34 -04:00