wallet-records-spaces: heartbeat-repoint greens off DNS cache, leaves apex mis-pointed #1656

Closed
opened 2026-09-20 06:35:01 +00:00 by matou-build-agent · 3 comments

The failure

Leg 40 of 40, wallet-records-spaces, is the only red (39 green, 0 skip). It died inside openHeadlessWallet at the wallet's second hop — client.connect() — not at the door and not on the credential. The descriptor read one line earlier succeeded, so the community's public face answered fine.

The real cause, which Playwright's bare TypeError: fetch failed hides, is a TCP connect timeout to keria.rehearsal-f.idss.nz:443 — a blackhole. That blackhole is the TEST-NET-3 mis-point the previous leg installed and never took back.

Evidence

artifacts/verdict.json:

"firstRedLeg": "wallet-records-spaces" · "legs": {"total": 40, "green": 39, "red": 1, "skip": 0}

artifacts/legs.json — the red and the leg immediately before it:

{ "leg": "heartbeat-repoint", "status": "green", "ms": 11503 },
{ "leg": "wallet-records-spaces", "status": "red", "ms": 10883, "error": "fetch failed" }

trace.zip → test.trace, the cause behind the bare message:

"TypeError: fetch failed\n[cause]: ConnectTimeoutError: Connect Timeout Error (attempted address: keria.rehearsal-f.idss.nz:443, timeout: 10000ms)"
at SignifyClient.connect ... at openHeadlessWallet (app/tests/e2e/fixtures/headlessWallet.ts:105:3)

A connect timeout — not refusal, not TLS, not a 404: the name resolved and nothing answered. The leg's own 10883 ms ≈ signify.ready() + undici's 10 000 ms connect ceiling.

Live box (134.199.166.118) — ssh accepted, read-only. The product side is healthy:

  • systemctl --failed --no-legend → empty.
  • Cert-verified (no -k), --resolved straight at the droplet: apex /api/client-config http=200, keria.rehearsal-f.idss.nz http=401, keria-boot.… http=403. The door the wallet wanted answers when you reach the box by address.
  • The descriptor it serves advertises "admin_url": "https://keria.rehearsal-f.idss.nz" — the exact name that timed out.

The box's own journal proves the heartbeat never re-pointed in that window (journalctl -u idss-control-plane):

06:14:29 "address heartbeat wired: keeping the community's idss.nz record current against gateway-IP churn (ADR 0136)" apex=rehearsal-f.idss.nz
06:19:59 "address heartbeat started" interval=5m0s
06:20:05 "address heartbeat: gateway address changed, community record re-pointed" ip=134.199.166.118
06:30:05 level=ERROR "address heartbeat failing: gateway address changed but the record could not be re-pointed …" err="brokerclient: /v1/subdomains/point: 400 Bad Request: broker: host is not a claimed subdomain of this zone"

Last successful re-point 06:20:05, interval 5 m, next tick 06:30:05 — and that one failed. The leg mis-pointed at ~06:27:03 and went green at ~06:27:14. No correction ran in between. The green is a read of the resolver cache.

The poll that produced it — heartbeatRepoint (app/tests/e2e/journey.idip.spec.ts:1397) and app/tests/e2e/fixtures/selfhosted.ts:

export const MISPOINT_IP = '203.0.113.250'; ← TEST-NET-3, never routes, never answers TCP
const { stdout } = await exec('dig', ['+short', host], { timeout: 20_000 }); ← system resolver; no @<authoritative NS>, no +trace, no cache bypass
if (digAnswers(last, ip)) break; ← exits on the first poll whose output contains the droplet IP

So: the mis-point POSTs 2xx (the leg throws on non-2xx and did not), the zone record becomes 203.0.113.250, dig +short keeps serving the cached droplet answer for the record's TTL, the loop breaks on its first poll, green. Then wallet-records-spaces — the first Node-side, by-name caller after it — resolves keria.rehearsal-f.idss.nz fresh (the apex was already warm in that process, which is exactly why the descriptor fetch at headlessWallet.ts:88 still got its 200), lands on TEST-NET-3, and burns the 10 s timeout.

Today, all rehearsal-f names answer 143.198.134.168 from 1.1.1.1 — neither the droplet (whose only public address is wan0 134.199.166.118) nor the mis-point. Something re-claimed the host after the run; the broker's 06:30 refusal says this community's claim is gone. Not attributable from this run directory.

Absent

  • artifacts/wallet-records-spaces.json was never written — the evidence write sits after openHeadlessWallet, so the leg died before its own artifact existed. No challenge/post record to read.
  • logs/broker-journal.txt is only a refusal: dev@100.98.48.68: Permission denied (publickey) — the broker's side of the mis-point and of the claim lapse is unreadable from here.
  • No skip reasons anywhere in legs.json (skip: 0), and pair is green (4699 ms). The own-VPS pairing carrier frontier named in the brief is not in play — this is a fresh red, not the known one.
  • logs/guest-*.log are private-path collectors and are inapplicable on the VPS path (Unit idss-guest.service could not be found); host.json's qemu: spawn qemu-system-x86_64 ENOENT agrees.

Suspected layer

Harness — the drive's own heartbeat-repoint leg. Two defects, one root:

  1. No "the mis-point landed" gate. The leg must first observe the record answering MISPOINT_IP, and only then start the clock on the correction. As written, a cached pre-mis-point answer satisfies the success predicate instantly — which is the most likely way for this leg to pass, not an edge case.
  2. The poll reads a cache, not the record. digShort asks the system resolver, so it cannot see the zone it is asserting about.

The consequence reaches past the false green: the leg leaves the community's DNS pointed at a blackhole and every later leg inherits it. wallet-records-spaces is the victim only because it sits immediately after and is the one leg that resolves by name from Node — no browser --host-resolver-rules, the non-browser caller GOTCHAS #281 describes.

Secondary, and not settled here: the 06:30:05 tick failed with host is not a claimed subdomain of this zone. Even a correctly-waiting leg would have red at its 15-minute ceiling, because the gateway could no longer re-point at all. Whether that claim lapse is teardown, a broker TTL reap (ADR 0189), or a slot hand-off (#663 / ADR 0003) needs the broker journal this run could not harvest — a human or a broker-side read, not a code change.

What plugging it needs

  1. In heartbeatRepoint (app/tests/e2e/journey.idip.spec.ts:1397): after the 2xx mis-point, poll until the record answers MISPOINT_IP under its own short ceiling; only then begin polling for the droplet. Red distinctly if the mis-point never lands — that is a broker gap, not a heartbeat one.
  2. Point the poll at authority: give digShort an @ns argument (dig +short @andy.ns.cloudflare.com <host>) or +trace, so no cache can answer for the zone.
  3. Restore the record on the way out. The leg holds the claim secret; it should re-point to ip itself in a finally rather than leave the community's DNS broken for the legs behind it and rely on a 5-minute heartbeat to repair it. This alone de-couples wallet-records-spaces from this leg.
  4. Cheap guard for the victim: have openHeadlessWallet fold err.cause into its throw. TypeError: fetch failed cost a trace extraction to become ConnectTimeoutError … keria.rehearsal-f.idss.nz:443.

Legs 1–39 are honest and the gateway is healthy; only the tail needs re-driving once (1)–(3) land.

drive 20260920T060311Z red at wallet-records-spaces: fetch failed
evidence: /home/swarm/session-runner/idss/test-results/drive-idip/20260920T060311Z on matou-workstation (legs.json and whatever else the drive harvested there) — a representative screenshot is attached here if one was captured

## The failure Leg 40 of 40, `wallet-records-spaces`, is the only red (39 green, **0 skip**). It died inside `openHeadlessWallet` at the wallet's *second* hop — `client.connect()` — not at the door and not on the credential. The descriptor read one line earlier succeeded, so the community's public face answered fine. The real cause, which Playwright's bare `TypeError: fetch failed` hides, is a **TCP connect timeout to `keria.rehearsal-f.idss.nz:443`** — a blackhole. That blackhole is the TEST-NET-3 mis-point the *previous* leg installed and never took back. ## Evidence `artifacts/verdict.json`: > `"firstRedLeg": "wallet-records-spaces"` · `"legs": {"total": 40, "green": 39, "red": 1, "skip": 0}` `artifacts/legs.json` — the red and the leg immediately before it: > `{ "leg": "heartbeat-repoint", "status": "green", "ms": 11503 },` > `{ "leg": "wallet-records-spaces", "status": "red", "ms": 10883, "error": "fetch failed" }` `trace.zip` → `test.trace`, the cause behind the bare message: > `"TypeError: fetch failed\n[cause]: ConnectTimeoutError: Connect Timeout Error (attempted address: keria.rehearsal-f.idss.nz:443, timeout: 10000ms)"` > `at SignifyClient.connect ... at openHeadlessWallet (app/tests/e2e/fixtures/headlessWallet.ts:105:3)` A connect *timeout* — not refusal, not TLS, not a 404: the name resolved and nothing answered. The leg's own `10883 ms` ≈ `signify.ready()` + undici's 10 000 ms connect ceiling. **Live box (134.199.166.118) — ssh accepted, read-only. The product side is healthy:** - `systemctl --failed --no-legend` → empty. - Cert-verified (no `-k`), `--resolve`d straight at the droplet: apex `/api/client-config` **http=200**, `keria.rehearsal-f.idss.nz` **http=401**, `keria-boot.…` **http=403**. The door the wallet wanted answers when you reach the box by address. - The descriptor it serves advertises `"admin_url": "https://keria.rehearsal-f.idss.nz"` — the exact name that timed out. **The box's own journal proves the heartbeat never re-pointed in that window** (`journalctl -u idss-control-plane`): > `06:14:29 "address heartbeat wired: keeping the community's idss.nz record current against gateway-IP churn (ADR 0136)" apex=rehearsal-f.idss.nz` > `06:19:59 "address heartbeat started" interval=5m0s` > `06:20:05 "address heartbeat: gateway address changed, community record re-pointed" ip=134.199.166.118` > `06:30:05 level=ERROR "address heartbeat failing: gateway address changed but the record could not be re-pointed …" err="brokerclient: /v1/subdomains/point: 400 Bad Request: broker: host is not a claimed subdomain of this zone"` Last successful re-point **06:20:05**, interval **5 m**, next tick **06:30:05** — and that one *failed*. The leg mis-pointed at ~06:27:03 and went green at ~06:27:14. **No correction ran in between.** The green is a read of the resolver cache. The poll that produced it — `heartbeatRepoint` (`app/tests/e2e/journey.idip.spec.ts:1397`) and `app/tests/e2e/fixtures/selfhosted.ts`: > `export const MISPOINT_IP = '203.0.113.250';` ← TEST-NET-3, never routes, never answers TCP > `const { stdout } = await exec('dig', ['+short', host], { timeout: 20_000 });` ← system resolver; no `@<authoritative NS>`, no `+trace`, no cache bypass > `if (digAnswers(last, ip)) break;` ← exits on the *first* poll whose output contains the droplet IP So: the mis-point POSTs 2xx (the leg throws on non-2xx and did not), the zone record becomes `203.0.113.250`, `dig +short` keeps serving the cached droplet answer for the record's TTL, the loop breaks on its first poll, green. Then `wallet-records-spaces` — the first **Node-side, by-name** caller after it — resolves `keria.rehearsal-f.idss.nz` *fresh* (the apex was already warm in that process, which is exactly why the descriptor fetch at `headlessWallet.ts:88` still got its 200), lands on TEST-NET-3, and burns the 10 s timeout. Today, all `rehearsal-f` names answer `143.198.134.168` from 1.1.1.1 — neither the droplet (whose only public address is `wan0 134.199.166.118`) nor the mis-point. Something re-claimed the host after the run; the broker's 06:30 refusal says this community's claim is gone. Not attributable from this run directory. ## Absent - **`artifacts/wallet-records-spaces.json` was never written** — the evidence write sits after `openHeadlessWallet`, so the leg died before its own artifact existed. No challenge/post record to read. - **`logs/broker-journal.txt` is only a refusal**: `dev@100.98.48.68: Permission denied (publickey)` — the broker's side of the mis-point and of the claim lapse is unreadable from here. - **No skip reasons anywhere in `legs.json`** (`skip: 0`), and **`pair` is green** (`4699 ms`). The own-VPS pairing carrier frontier named in the brief is **not** in play — this is a fresh red, not the known one. - `logs/guest-*.log` are private-path collectors and are inapplicable on the VPS path (`Unit idss-guest.service could not be found`); `host.json`'s `qemu: spawn qemu-system-x86_64 ENOENT` agrees. ## Suspected layer **Harness** — the drive's own `heartbeat-repoint` leg. Two defects, one root: 1. **No "the mis-point landed" gate.** The leg must first observe the record answering `MISPOINT_IP`, and only then start the clock on the correction. As written, a cached pre-mis-point answer satisfies the success predicate instantly — which is the *most likely* way for this leg to pass, not an edge case. 2. **The poll reads a cache, not the record.** `digShort` asks the system resolver, so it cannot see the zone it is asserting about. The consequence reaches past the false green: the leg leaves the community's DNS pointed at a blackhole and every later leg inherits it. `wallet-records-spaces` is the victim only because it sits immediately after and is the one leg that resolves by name from Node — no browser `--host-resolver-rules`, the non-browser caller GOTCHAS #281 describes. **Secondary, and *not* settled here:** the 06:30:05 tick failed with `host is not a claimed subdomain of this zone`. Even a correctly-waiting leg would have red at its 15-minute ceiling, because the gateway could no longer re-point at all. Whether that claim lapse is teardown, a broker TTL reap (ADR 0189), or a slot hand-off (#663 / ADR 0003) needs the broker journal this run could not harvest — a human or a broker-side read, not a code change. ## What plugging it needs 1. In `heartbeatRepoint` (`app/tests/e2e/journey.idip.spec.ts:1397`): after the 2xx mis-point, poll until the record **answers `MISPOINT_IP`** under its own short ceiling; only then begin polling for the droplet. Red distinctly if the mis-point never lands — that is a broker gap, not a heartbeat one. 2. Point the poll at authority: give `digShort` an `@ns` argument (`dig +short @andy.ns.cloudflare.com <host>`) or `+trace`, so no cache can answer for the zone. 3. **Restore the record on the way out.** The leg holds the claim secret; it should re-point to `ip` itself in a `finally` rather than leave the community's DNS broken for the legs behind it and rely on a 5-minute heartbeat to repair it. This alone de-couples `wallet-records-spaces` from this leg. 4. Cheap guard for the victim: have `openHeadlessWallet` fold `err.cause` into its throw. `TypeError: fetch failed` cost a trace extraction to become `ConnectTimeoutError … keria.rehearsal-f.idss.nz:443`. Legs 1–39 are honest and the gateway is healthy; only the tail needs re-driving once (1)–(3) land. drive `20260920T060311Z` red at `wallet-records-spaces`: `fetch failed` evidence: `/home/swarm/session-runner/idss/test-results/drive-idip/20260920T060311Z` on matou-workstation (legs.json and whatever else the drive harvested there) — a representative screenshot is attached here if one was captured <!-- rehearsal-sig: 46719fb9729e -->
Author
Member

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

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

Note from Ben's session (author of the wallet-records-spaces leg): the ordering half is already landed — e47c1ce7 moves the wallet leg to just BEFORE heartbeat-repoint, with the reason in the spec comment. Keep it there: nothing that dials the community's names from the drive host may run after the mis-point. This ticket is therefore only the heartbeat-repoint false green itself — (1) gate on first OBSERVING MISPOINT_IP at the authoritative NS before starting the correction clock, (2) poll the record (dig @<authoritative NS>), never the system resolver's cache. The 06:30:05 host is not a claimed subdomain error in the box journal is after the drive's own teardown offboarded the slug (offboard rehearsal-f.idss.nz: 204) — expected, not a product fault.

Note from Ben's session (author of the `wallet-records-spaces` leg): the ordering half is already landed — `e47c1ce7` moves the wallet leg to just BEFORE `heartbeat-repoint`, with the reason in the spec comment. **Keep it there**: nothing that dials the community's names from the drive host may run after the mis-point. This ticket is therefore only the `heartbeat-repoint` false green itself — (1) gate on first OBSERVING `MISPOINT_IP` at the authoritative NS before starting the correction clock, (2) poll the record (`dig @<authoritative NS>`), never the system resolver's cache. The 06:30:05 `host is not a claimed subdomain` error in the box journal is after the drive's own teardown offboarded the slug (`offboard rehearsal-f.idss.nz: 204`) — expected, not a product fault.
Author
Member

close-report for #1656 — status success

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

envelope
{
  "issue": 1656,
  "status": "success",
  "commits": [
    "4773efe617947df974c71fc83dfe15b29d0ee504"
  ],
  "changed_files": [
    "STATUS.md",
    "docs/GOTCHAS.md",
    "app/tests/e2e/fixtures/headlessWallet.ts",
    "app/tests/e2e/fixtures/selfhosted.test.ts",
    "app/tests/e2e/fixtures/selfhosted.ts",
    "app/tests/e2e/journey.idip.spec.ts"
  ],
  "tests": [
    {
      "command": "cd app && CI=true pnpm exec vitest run tests/e2e/fixtures/selfhosted.test.ts",
      "exit_code": 0
    },
    {
      "command": "cd app && CI=true pnpm exec vue-tsc -p tsconfig.json --noEmit",
      "exit_code": 0
    },
    {
      "command": "cd app && CI=true pnpm exec eslint tests/e2e/fixtures/selfhosted.ts tests/e2e/fixtures/selfhosted.test.ts tests/e2e/fixtures/headlessWallet.ts tests/e2e/journey.idip.spec.ts",
      "exit_code": 0
    }
  ],
  "criteria": {
    "(1) after the 2xx mis-point, poll until the record answers MISPOINT_IP under its own short ceiling; only then begin polling for the droplet; red distinctly if the mis-point never lands": "journey.idip.spec.ts heartbeatRepoint now runs two pollRepoint gates driving the pure nextRepointPhase state machine — gate 1 waits on MISPOINT_IP under CEILING.mispointLands and reds with a distinct 'broker did not apply /v1/subdomains/point (a broker gap, not a heartbeat one)' message; gate 2 then waits on the droplet. Proven offline by selfhosted.test.ts 'nextRepointPhase' (a cached droplet answer does NOT advance past mispoint).",
    "(2) point the poll at authority (dig +short @ns <host> or +trace) so no cache can answer for the zone": "journey.idip.spec.ts authoritativeNs resolves the zone's NS once and digShort(host, ns) runs `dig +short @<ns> <host>` via digArgs; fixtures/selfhosted.ts digArgs + authorityZone are pure, tested in selfhosted.test.ts 'digArgs'/'authorityZone'.",
    "(3) restore the record on the way out — re-point to ip itself in a finally rather than leave the community's DNS broken": "journey.idip.spec.ts heartbeatRepoint wraps both gates in try/finally; the finally POSTs pointBody(host, ip) with the claim secret, best-effort, logging the status.",
    "(4) cheap guard for the victim: openHeadlessWallet folds err.cause into its throw": "fixtures/headlessWallet.ts withCause folds an Error's [cause] into its message; applied via .catch(withCause) on the descriptor fetch, client.connect(), and both recordSpaces fetches."
  },
  "summary": "heartbeat-repoint now gates on the mis-point landing at authority, queries the authoritative NS (not the cache), and restores the record in a finally; openHeadlessWallet folds err.cause into its throws.",
  "reason": "",
  "blockers": [],
  "no_code_change": ""
}
**close-report** for #1656 — status `success` :white_check_mark: **close-report gates passed** — every claim verified against main; issue closed. <details><summary>envelope</summary> ```json { "issue": 1656, "status": "success", "commits": [ "4773efe617947df974c71fc83dfe15b29d0ee504" ], "changed_files": [ "STATUS.md", "docs/GOTCHAS.md", "app/tests/e2e/fixtures/headlessWallet.ts", "app/tests/e2e/fixtures/selfhosted.test.ts", "app/tests/e2e/fixtures/selfhosted.ts", "app/tests/e2e/journey.idip.spec.ts" ], "tests": [ { "command": "cd app && CI=true pnpm exec vitest run tests/e2e/fixtures/selfhosted.test.ts", "exit_code": 0 }, { "command": "cd app && CI=true pnpm exec vue-tsc -p tsconfig.json --noEmit", "exit_code": 0 }, { "command": "cd app && CI=true pnpm exec eslint tests/e2e/fixtures/selfhosted.ts tests/e2e/fixtures/selfhosted.test.ts tests/e2e/fixtures/headlessWallet.ts tests/e2e/journey.idip.spec.ts", "exit_code": 0 } ], "criteria": { "(1) after the 2xx mis-point, poll until the record answers MISPOINT_IP under its own short ceiling; only then begin polling for the droplet; red distinctly if the mis-point never lands": "journey.idip.spec.ts heartbeatRepoint now runs two pollRepoint gates driving the pure nextRepointPhase state machine — gate 1 waits on MISPOINT_IP under CEILING.mispointLands and reds with a distinct 'broker did not apply /v1/subdomains/point (a broker gap, not a heartbeat one)' message; gate 2 then waits on the droplet. Proven offline by selfhosted.test.ts 'nextRepointPhase' (a cached droplet answer does NOT advance past mispoint).", "(2) point the poll at authority (dig +short @ns <host> or +trace) so no cache can answer for the zone": "journey.idip.spec.ts authoritativeNs resolves the zone's NS once and digShort(host, ns) runs `dig +short @<ns> <host>` via digArgs; fixtures/selfhosted.ts digArgs + authorityZone are pure, tested in selfhosted.test.ts 'digArgs'/'authorityZone'.", "(3) restore the record on the way out — re-point to ip itself in a finally rather than leave the community's DNS broken": "journey.idip.spec.ts heartbeatRepoint wraps both gates in try/finally; the finally POSTs pointBody(host, ip) with the claim secret, best-effort, logging the status.", "(4) cheap guard for the victim: openHeadlessWallet folds err.cause into its throw": "fixtures/headlessWallet.ts withCause folds an Error's [cause] into its message; applied via .catch(withCause) on the descriptor fetch, client.connect(), and both recordSpaces fetches." }, "summary": "heartbeat-repoint now gates on the mis-point landing at authority, queries the authoritative NS (not the cache), and restores the record in a finally; openHeadlessWallet folds err.cause into its throws.", "reason": "", "blockers": [], "no_code_change": "" } ``` </details>
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
Matou/idss#1656
No description provided.