artifacts/journey.json serialises {"rows":null,"fault":null} on a faulted device drive, dropping the founding-rows snapshot (seen on drive 20260828T051317Z) #928

Closed
opened 2026-08-28 06:20:56 +00:00 by matou-build-agent · 3 comments

Symptom

On drive 20260828T051317Z (target device), artifacts/journey.json is:

{"rows": null, "fault": null}

— no founding rows and no fault captured, even though the fault was fully recorded elsewhere in the same drive: artifacts/legs.json carries the enroll-configure/standing reds verbatim, and logs/founding-state.log carries the full event stream. So journey.json is the one artifact that silently dropped the founding evidence a diagnosing agent would reach for first.

Why it matters

journey.json is meant to be the structured founding-rows + fault snapshot (the counterpart to the log stream). When it serialises null/null on a drive that genuinely faulted, a post-hoc diagnosis has to fall back to legs.json + founding-state.log (which happened here) — and a drive whose logs were also thin would be left with no structured founding record at all.

Scope

Separate from the config_eval race (#924, a completion of #923 — both now landed). Surfaced as "Also in this run" residue #2 on #924. Likely a capture/serialisation gap on the device-target path where founding rows aren't threaded into journey.json before it's written (the fault IS known to the run — legs.json has it — so this is a wiring/ordering gap, not a missing fact).

First step for whoever picks this up

Find where journey.json is written on the device/rented founding path and why rows/fault are nil there while legs.json and founding-state.log are populated — likely the journey snapshot is taken before (or without) the founding orchestrator's rows/fault being copied in.

Filed under ADR 0174 as a two-way follow-up; not fixed in #924's session (rule 1 — one ticket per session).

## Symptom On drive `20260828T051317Z` (target `device`), `artifacts/journey.json` is: ```json {"rows": null, "fault": null} ``` — no founding rows and no fault captured, **even though the fault was fully recorded elsewhere** in the same drive: `artifacts/legs.json` carries the `enroll-configure`/`standing` reds verbatim, and `logs/founding-state.log` carries the full event stream. So `journey.json` is the one artifact that silently dropped the founding evidence a diagnosing agent would reach for first. ## Why it matters `journey.json` is meant to be the structured founding-rows + fault snapshot (the counterpart to the log stream). When it serialises `null`/`null` on a drive that genuinely faulted, a post-hoc diagnosis has to fall back to `legs.json` + `founding-state.log` (which happened here) — and a drive whose logs were also thin would be left with no structured founding record at all. ## Scope Separate from the config_eval race (#924, a completion of #923 — both now landed). Surfaced as "Also in this run" residue #2 on #924. Likely a capture/serialisation gap on the `device`-target path where founding rows aren't threaded into `journey.json` before it's written (the fault IS known to the run — `legs.json` has it — so this is a wiring/ordering gap, not a missing fact). ## First step for whoever picks this up Find where `journey.json` is written on the device/rented founding path and why `rows`/`fault` are `nil` there while `legs.json` and `founding-state.log` are populated — likely the journey snapshot is taken before (or without) the founding orchestrator's rows/fault being copied in. Filed under ADR 0174 as a two-way follow-up; not fixed in #924's session (rule 1 — one ticket per session).
Author
Member

This was generated by AI during triage.

Agent Brief

Category: bug
Summary: Thread the founding rows + fault snapshot into artifacts/journey.json on the journey.* e2e paths, which currently harvest without them and serialise {"rows":null,"fault":null}

Current behavior:
On a faulted device-target drive, artifacts/journey.json is {"rows": null, "fault": null} — the founding-rows/fault snapshot is dropped — even though the fault is fully recorded elsewhere in the same drive (artifacts/legs.json carries the reds verbatim; logs/founding-state.log carries the event stream). journey.json is the one artifact that silently drops the structured founding evidence a diagnosing agent reaches for first. Seen on drive 20260828T051317Z.

Root cause (confirmed during triage): the journey harvest fixture serialises { rows: opts.rows ?? null, fault: opts.fault ?? null }, and the journey.* specs call harvest(live) with no { rows, fault } argument — unlike the private-path family of live specs, which pass { rows: lastSnap, fault: lastFault }. So on the founding/journey paths the snapshot is never threaded in.

Desired behavior:
On the founding/journey drive paths (device, and its rented/self-hosted/idip siblings that harvest the same way), the harvest passes the run's current founding-rows snapshot and recorded fault into the journey artifact, so a faulted drive's journey.json carries the founding rows and the fault — matching the fact already present in legs.json/founding-state.log. A clean run is unchanged.

Key interfaces:

  • The journey-harvest call on the journey.* e2e specs — it must thread the same { rows, fault } snapshot the private-path-family specs already pass (the latest rows snapshot + latest recorded fault), rather than calling harvest bare.
  • Reuse the existing rows/fault-tracking the private-path specs use; don't invent a second snapshot mechanism.

Acceptance criteria:

  • On a faulted founding/journey drive, artifacts/journey.json contains the founding rows and the fault (non-null), consistent with legs.json.
  • A clean (non-faulted) run's journey.json is unchanged.
  • A test (e2e fixture-level or offline) asserts the journey harvest threads a non-null rows/fault snapshot when one exists on the faulted path.

Out of scope:

  • The serialisation shape of journey.json itself (keep {rows, fault}).
  • The other three drive-20260828T051317Z defects (#925, #926, #927).

Ruled by agent under ADR 0174 — veto anytime.
Ruling: ready-for-agent. Two-way door — a wiring/ordering fix in the e2e harvest (thread an already-tracked snapshot into one artifact write), revertible by a commit and provable offline against the journey fixture; the fault is already known to the run, so no live drive is required to prove the fix. Not on the one-way-door list. Safe for the swarm.

> *This was generated by AI during triage.* ## Agent Brief **Category:** bug **Summary:** Thread the founding rows + fault snapshot into `artifacts/journey.json` on the `journey.*` e2e paths, which currently harvest without them and serialise `{"rows":null,"fault":null}` **Current behavior:** On a faulted `device`-target drive, `artifacts/journey.json` is `{"rows": null, "fault": null}` — the founding-rows/fault snapshot is dropped — **even though the fault is fully recorded elsewhere in the same drive** (`artifacts/legs.json` carries the reds verbatim; `logs/founding-state.log` carries the event stream). `journey.json` is the one artifact that silently drops the structured founding evidence a diagnosing agent reaches for first. Seen on drive `20260828T051317Z`. Root cause (confirmed during triage): the journey harvest fixture serialises `{ rows: opts.rows ?? null, fault: opts.fault ?? null }`, and the `journey.*` specs call `harvest(live)` with **no `{ rows, fault }` argument** — unlike the private-path family of live specs, which pass `{ rows: lastSnap, fault: lastFault }`. So on the founding/journey paths the snapshot is never threaded in. **Desired behavior:** On the founding/journey drive paths (device, and its rented/self-hosted/idip siblings that harvest the same way), the harvest passes the run's current founding-rows snapshot and recorded fault into the journey artifact, so a faulted drive's `journey.json` carries the founding rows and the fault — matching the fact already present in `legs.json`/`founding-state.log`. A clean run is unchanged. **Key interfaces:** - The journey-harvest call on the `journey.*` e2e specs — it must thread the same `{ rows, fault }` snapshot the private-path-family specs already pass (the latest rows snapshot + latest recorded fault), rather than calling harvest bare. - Reuse the existing rows/fault-tracking the private-path specs use; don't invent a second snapshot mechanism. **Acceptance criteria:** - [ ] On a faulted founding/journey drive, `artifacts/journey.json` contains the founding rows and the fault (non-null), consistent with `legs.json`. - [ ] A clean (non-faulted) run's `journey.json` is unchanged. - [ ] A test (e2e fixture-level or offline) asserts the journey harvest threads a non-null rows/fault snapshot when one exists on the faulted path. **Out of scope:** - The serialisation shape of `journey.json` itself (keep `{rows, fault}`). - The other three drive-`20260828T051317Z` defects (#925, #926, #927). --- Ruled by agent under ADR 0174 — veto anytime. **Ruling:** `ready-for-agent`. Two-way door — a wiring/ordering fix in the e2e harvest (thread an already-tracked snapshot into one artifact write), revertible by a commit and provable offline against the journey fixture; the fault is already known to the run, so no live drive is required to prove the fix. Not on the one-way-door list. Safe for the swarm.
Author
Member

swarm-claim host=matou-dev-server-01 run=13097
(automated multi-host claim — lowest live claim id works this ticket)

swarm-claim host=matou-dev-server-01 run=13097 (automated multi-host claim — lowest live claim id works this ticket)
Author
Member

close-report for #928 — status success

✅ close-report gates passed — every claim verified against main; issue closed.

envelope
{
  "issue": 928,
  "status": "success",
  "commits": [
    "6b1346f02546cc5ffa752e04fa3dda42b573d546"
  ],
  "changed_files": [
    "app/tests/e2e/fixtures/legs.test.ts",
    "app/tests/e2e/fixtures/legs.ts",
    "app/tests/e2e/journey.device.spec.ts",
    "app/tests/e2e/journey.droplet.spec.ts",
    "app/tests/e2e/journey.idip.spec.ts",
    "app/tests/e2e/journey.rented.spec.ts",
    "app/tests/e2e/journey.selfhosted.spec.ts"
  ],
  "tests": [
    {
      "command": "npx vitest run tests/e2e/fixtures/legs.test.ts",
      "exit_code": 0
    }
  ],
  "criteria": {
    "On a faulted founding/journey drive, artifacts/journey.json contains the founding rows and the fault (non-null), consistent with legs.json": "legs.ts:journeyEvidence returns {rows: records, fault: <first red leg error>} on a faulted registry; all five journey specs now call harvest(live, journeyEvidence(legRecords)) (commit 6b1346f0) so journey.json's {rows,fault} carry the same legRecords that back legs.json. Proven by legs.test.ts 'threads the leg rows + the first red leg error on a faulted drive'.",
    "A clean (non-faulted) run's journey.json is unchanged": "journeyEvidence returns {} on an all-green/skip registry, so harvest writes {rows:null,fault:null} exactly as before. Proven by legs.test.ts 'returns {} on a clean drive so journey.json stays {\"rows\":null,\"fault\":null} unchanged'.",
    "A test (e2e fixture-level or offline) asserts the journey harvest threads a non-null rows/fault snapshot when one exists on the faulted path": "tests/e2e/fixtures/legs.test.ts adds a journeyEvidence describe with faulted, hung, and clean cases; npx vitest run tests/e2e/fixtures/legs.test.ts → 17 passed."
  },
  "summary": "The journey drives now thread the legRecords rows + first-red fault into artifacts/journey.json, so a faulted drive's journey.json matches legs.json instead of serialising {rows:null,fault:null}.",
  "blockers": []
}
**close-report** for #928 — status `success` :white_check_mark: **close-report gates passed** — every claim verified against main; issue closed. <details><summary>envelope</summary> ```json { "issue": 928, "status": "success", "commits": [ "6b1346f02546cc5ffa752e04fa3dda42b573d546" ], "changed_files": [ "app/tests/e2e/fixtures/legs.test.ts", "app/tests/e2e/fixtures/legs.ts", "app/tests/e2e/journey.device.spec.ts", "app/tests/e2e/journey.droplet.spec.ts", "app/tests/e2e/journey.idip.spec.ts", "app/tests/e2e/journey.rented.spec.ts", "app/tests/e2e/journey.selfhosted.spec.ts" ], "tests": [ { "command": "npx vitest run tests/e2e/fixtures/legs.test.ts", "exit_code": 0 } ], "criteria": { "On a faulted founding/journey drive, artifacts/journey.json contains the founding rows and the fault (non-null), consistent with legs.json": "legs.ts:journeyEvidence returns {rows: records, fault: <first red leg error>} on a faulted registry; all five journey specs now call harvest(live, journeyEvidence(legRecords)) (commit 6b1346f0) so journey.json's {rows,fault} carry the same legRecords that back legs.json. Proven by legs.test.ts 'threads the leg rows + the first red leg error on a faulted drive'.", "A clean (non-faulted) run's journey.json is unchanged": "journeyEvidence returns {} on an all-green/skip registry, so harvest writes {rows:null,fault:null} exactly as before. Proven by legs.test.ts 'returns {} on a clean drive so journey.json stays {\"rows\":null,\"fault\":null} unchanged'.", "A test (e2e fixture-level or offline) asserts the journey harvest threads a non-null rows/fault snapshot when one exists on the faulted path": "tests/e2e/fixtures/legs.test.ts adds a journeyEvidence describe with faulted, hung, and clean cases; npx vitest run tests/e2e/fixtures/legs.test.ts → 17 passed." }, "summary": "The journey drives now thread the legRecords rows + first-red fault into artifacts/journey.json, so a faulted drive's journey.json matches legs.json instead of serialising {rows:null,fault:null}.", "blockers": [] } ``` </details>
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Matou/idss#928
No description provided.