From 915d309e14f9c1ca99ce1ea8acb29b48ef91793f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C5=ABdolfs=20O=C5=A1i=C5=86=C5=A1?= Date: Thu, 21 May 2026 10:20:10 +0200 Subject: [PATCH] Tolerate null agent in /node response MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Public seeds return `"agent": null` because their deployed httpd binaries can't parse i2p/onion rows that newer nodes write to the address table — `AddressStore::get` fails and the handler falls back to `None`. Allow null in the zod schema and hide the user-agent row in the UI when it's missing. Workaround until heartwood ships `StoreExt::agent_of` (reads only the `agent` column, no address hydration) and httpd adopts it. --- http-client/index.ts | 2 +- src/views/nodes/View.svelte | 8 +++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/http-client/index.ts b/http-client/index.ts index 3fb09696e..7f30904a2 100644 --- a/http-client/index.ts +++ b/http-client/index.ts @@ -97,7 +97,7 @@ export type Node = z.infer; const nodeSchema = z.object({ id: z.string(), - agent: z.string(), + agent: z.string().nullable(), config: nodeConfigSchema.nullable(), state: z.union([z.literal("running"), z.literal("stopped")]), avatarUrl: z.string().optional(), diff --git a/src/views/nodes/View.svelte b/src/views/nodes/View.svelte index f6e12c77c..55eea229a 100644 --- a/src/views/nodes/View.svelte +++ b/src/views/nodes/View.svelte @@ -166,9 +166,11 @@
- + {#if node.agent} + + {/if}