Skip to main content

Module bundle

Module bundle 

Source

Modules§

reader
Reading run bundles from disk: manifest discovery, full bundle loads, and artifact resolution. Malformed bundles are skipped, matching the TypeScript store’s listRunBundles behavior.
tail
Incremental NDJSON tailing. trace.ndjson and session/entries.ndjson are append-only, so a tailer only ever reads bytes past its offset. A partial trailing line (a writer mid-append) is buffered until the newline arrives. Truncation (which the format forbids) resets the tailer.
types
Serde types mirroring the run bundle documents specified in docs/run-bundles.md. Unknown fields are tolerated everywhere so bundles written by newer writers within the same schema version stay readable.
watch
Filesystem watching for the runs directory. Events are debounced into a single “something changed” tick on a tokio channel; consumers rescan the directory and poll their tailers, which is cheap and race-free because all bundle files are either append-only or atomically replaced.