Your browser sucks, JavaScript disabled! Gunnar's console needs JavaScript and WebAssembly. Git over SSH on port 2222 does not.

nordisk/edda

crates/nornir-saga/.nornir/saga-design.md

Saga — design

nornir-saga: capture a user's navigation as structured events → persist to the nornir warehouse → the test matrix replays the path as a generated robot test for bug-finding + regression. The production sibling of nornir-testmatrix.

Lineage — two siblings, one pattern

emit real state from inside → nornir warehouse → read back.

nornir-testmatrix nornir-saga
Emits test verdicts (functional_status) navigation + log events (record(SagaEvent))
Gate feature testmatrix (dev/test, release-stripped) feature saga (production opt-in)
Sink nornir warehouse test_results nornir warehouse saga_events
Read back the matrix (green ⟺ emitted ok) matrix replays the path → robot test

Pieces

Toolkit-neutral core + adapters (the deferred "emitters")

The core has no UI/framework deps. Capture happens through thin adapters that build SagaEvents and call record:

Replay drivers mirror that split: egui → kittest / nornir-robotui, web app → a WebDriver driver against the live Leptos app. Adapters + drivers are the next phase; the core lands first.

The warehouse is always the nornir warehouse

Saga writes to the nornir warehouse — not a per-feature sink choice, no alternative backend at the saga layer. How the warehouse stores (or is later detached behind a trait) is a nornir concern, not saga's. See plan item WAREHOUSE-TRAIT.

Status

Foundation landed (task #25): event.rs + record.rs (capture buffer, saga feature) + sink.rs (SagaSink trait + JsonFileSink/NullSink) + replay.rs (ReplayPlan/ReplayStep, Nav/Click → steps) + lib.rs; the crate is a workspace member (nornir-saga = { path = … }, pulled WITHOUT the saga capture feature so release pays zero cost).

Deferred to phase 2: the capture adapters that emit saga_events from inside the apps — egui at the facett nav/Navigable boundary; Njord (Leptos router events client-side + an Axum middleware layer server-side). The web replay driver becomes live once those adapters record sessions. See nordisk_plan.md → SAGA.