kind discriminator and may carry fields added by newer engines.
Build a tolerant reducer
Keep settlement separate
RUN JOURNAL Β· TWO CONSUMERS
The UI can miss a frame, remount or ignore a new event. The outcome remains
the authority for completion and exit code.
Backpressure and cleanup
for await applies natural backpressure to journal processing. Keep each
event handler small. Send expensive storage or analytics work through a
bounded queue so stdout cannot remain unread indefinitely.
Always clear UI state in finally and use the callerβs AbortSignal to end
the child process when its request goes away.
Continue
Run and cancel
Open the stream and await the outcome.
Errors and exits
Keep run failure distinct from transport failure.
Receipts
Move from transient UI to durable proof.
Event concepts
Read the engine event vocabulary.