[AZ-265] Replay as configuration of airborne binary (ADR-011)

Re-design replay mode per user direction: replay is no longer a fourth
Docker image with a reduced component set, but a `config.mode = "replay"`
branch of the single airborne binary. The pre-flight workflow (route in
suite UI -> C12 tile download via real satellite-provider -> C10
manifest+engines build) is identical between live and replay; only three
strategies swap at compose time:

  FrameSource:      Live <-> Video
  FcAdapter:        Pymavlink/MSP2 <-> TlogReplay
  MavlinkTransport: Serial <-> Noop

The C8 outbound MAVLink encoders run unchanged in both modes; their
bytes hit `NoopMavlinkTransport` in replay and disappear. A new
`JsonlReplaySink` taps C5's `EstimatorOutput` stream so the parent-suite
UI sees per-tick coordinates by tailing `results.jsonl`. MAVLink 2.0
signing key remains mandatory (operator supplies a dummy file).

A new `replay_input/` Layer-4 cross-cutting coordinator owns
`(video, tlog) -> (FrameSource, FcAdapter, Clock)` convergence; the
composition root sees only standard interfaces past `.open()`.

Docs:
- architecture.md: new ADR-011 with full rationale; ADR-002 binary
  narrative updated.
- contracts/replay/replay_protocol.md: bumped to v2.0.0; 12 invariants
  (notably mode-agnosticism + encoder byte-equality + signing key
  mandatory + real C6 cache in replay).
- module-layout.md: Build-Time Exclusion Map dropped from 4 to 3 binary
  columns; replay-mode `BUILD_*` flags default ON in airborne;
  `shared/replay_input` cross-cutting entry added.
- epics.md: E-DEMO-REPLAY scope reframed; story points 27-32 -> 19-24.

Task respecs:
- AZ-401: shrunk 3 -> 2 pts; `compose_root` mode branch + JSONL sink +
  NoopMavlinkTransport wiring; legacy `compose_replay` export deleted.
- AZ-402: console-script wrapper that mutates `config.mode = "replay"`
  and dispatches into the shared airborne main; `--mavlink-signing-key`
  mandatory.
- AZ-403: CANCELLED. Moved to done/ with banner; Jira transition deferred
  via `_docs/_process_leftovers/2026-05-14_az_403_cancellation_pending_tracker.md`.
- AZ-404: AC-4 reworded as mode-agnosticism AST scan + encoder
  byte-equality test; new AC-8 operator-workflow rehearsal.
- AZ-405: also owns the `replay_input/` module + `ReplayInputAdapter`.

_dependencies_table.md updated: AZ-401 gains AZ-405 dep; AZ-404 drops
AZ-403 dep; AZ-403 row marked CANCELLED.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Oleksandr Bezdieniezhnykh
2026-05-14 09:01:04 +03:00
parent fa3742d582
commit 5adf3dd04f
13 changed files with 765 additions and 418 deletions
@@ -0,0 +1,49 @@
# Leftover — AZ-403 Jira transition to Cancelled (pending tracker write)
**Timestamp**: 2026-05-14T08:35:00+03:00
**Author**: agent (autodev cycle 1, Step 7 batch loop, replay-redesign docs phase)
## What was blocked
A Jira `transitionJiraIssue` call to move `AZ-403` (gps-denied-replay-cli Dockerfile + SBOM diff CI step) from its current status to **Cancelled**, plus a comment explaining the cancellation reason.
The transition was NOT performed during this docs phase because the docs phase did not touch the tracker (the replay-redesign was a docs-only change; the tracker write properly belongs to the next time autodev's tracker-write path runs, which is the standard implement / batch-loop step where Jira transitions happen).
## Full payload (replay this on next tracker-write opportunity)
```yaml
tracker: jira
cloudId: denyspopov.atlassian.net
projectKey: AZ
issueIdOrKey: AZ-403
action: transitionJiraIssue
target_status: Cancelled
comment: |
Cancelled per ADR-011 (replay-as-configuration; see `_docs/02_document/architecture.md`
§ ADR-011). The replay binary no longer exists as a separate Docker image — the airborne
image serves both live and replay modes from a single source tree with `config.mode = "replay"`
chosen at startup. No SBOM-diff CI step is needed because there are no per-replay
exclusions to enforce (C10/C11/C12 are already excluded from the airborne image by
ADR-002 + ADR-004; C6 is REQUIRED in replay per epic AZ-265 AC-3).
Original task file moved to `_docs/02_tasks/done/AZ-403_replay_dockerfile_ci.md` with a
cancellation banner; AZ-404's dependency on this ticket removed from
`_docs/02_tasks/_dependencies_table.md`. No replacement ticket — the replay-mode
console-script entry point ships from the airborne image via AZ-402.
```
## Reason for deferral
The current turn is a docs-only redesign; the tracker write properly belongs to the next tracker-touching step (autodev's standard implement / batch-loop tracker-transition step) so a single batched tracker pass picks up the AZ-403 cancellation alongside any other tracker transitions for AZ-401/402/404/405 if they accompany the implementation step.
This is a NON-user-input blocker (`.cursor/rules/tracker.mdc` Leftovers Mechanism qualifying case) — no user decision is pending; replaying the call is straightforward when the tracker is next touched.
## Replay obligation
At the next autodev start, OR at the next batch implementation step that performs Jira transitions, the agent MUST:
1. Read this file.
2. Issue the `transitionJiraIssue` call with the payload above.
3. On success → delete this file.
4. On failure → update the file timestamp + reason, surface to the user only if the failure shape requires user input (auth, missing transition target, missing permission).