{"version":285,"agent":"box-grants","message":"abso news --stream (abso 690): read the ticket's expiry as the ISO time the server sends (staging 1418) as well as milliseconds. It printed 'within NaN seconds', and the stream mark that stands the hooks mod's poll down came out NaN, so the poll kept running. Found in the staging proof. Tests: client/test/news-stream.test.ts.","time":1792119149637,"timeIso":"2026-10-16T02:52:29.637Z","changes":3,"change":4502,"files":["client/src/api.ts","client/src/news-stream.ts","client/test/news-stream.test.ts"],"draft":null,"diff":[{"path":"client/src/api.ts","added":1,"removed":1,"diff":"--- a/client/src/api.ts\n+++ b/client/src/api.ts\n@@ -1003,7 +1003,7 @@\n \t}\n \n \t/** A ticket that opens this agent's news stream once, within a minute (abso 690; news-stream.ts). */\n-\tnewsTicket(): Promise<{ url: string; protocols: string[]; expiresAt: number }> {\n+\tnewsTicket(): Promise<{ url: string; protocols: string[]; expiresAt: number | string }> {\n \t\treturn this.json(\"POST\", this.agentPath(\"news/ticket\"), {});\n \t}\n "},{"path":"client/src/news-stream.ts","added":10,"removed":3,"diff":"--- a/client/src/news-stream.ts\n+++ b/client/src/news-stream.ts\n@@ -15,9 +15,16 @@\n export interface NewsTicket {\n \treadonly url: string;\n \treadonly protocols: readonly string[];\n-\treadonly expiresAt: number;\n+\t/** When the ticket stops working: the server sends an ISO time; milliseconds are taken too. */\n+\treadonly expiresAt: number | string;\n }\n \n+/** A ticket's expiry in milliseconds, whichever form the server sent; now when it can't be read. */\n+export function expiresAtMs(ticket: NewsTicket, now: number): number {\n+\tconst at = typeof ticket.expiresAt === \"number\" ? ticket.expiresAt : Date.parse(ticket.expiresAt);\n+\treturn Number.isFinite(at) ? at : now;\n+}\n+\n /** A Monitor lasts at most 30 minutes; the skill re-arms it when it ends. */\n export const MONITOR_TIMEOUT_MS = 30 * 60_000;\n \n@@ -36,7 +43,7 @@\n \n /** The text --stream prints: the call to make, then the arguments as one line of JSON. */\n export function streamText(ticket: NewsTicket, project: string, agent: string, now = Date.now()): string {\n-\tconst seconds = Math.max(0, Math.round((ticket.expiresAt - now) / 1000));\n+\tconst seconds = Math.max(0, Math.round((expiresAtMs(ticket, now) - now) / 1000));\n \treturn [\n \t\t`Open this with Monitor within ${seconds} seconds (the ticket opens ${agent}'s news stream once). When the Monitor ends or the socket closes, run abso news --stream again; the new socket sends what arrived in between.`,\n \t\tJSON.stringify(monitorArgs(ticket, project, agent)),\n@@ -48,7 +55,7 @@\n \n /** How long --stream's mark holds: the Monitor's 30 minutes, and the minute the ticket waits to be used. */\n export function streamMarkUntil(ticket: NewsTicket, now: number): number {\n-\treturn Math.max(now, ticket.expiresAt) + MONITOR_TIMEOUT_MS;\n+\treturn Math.max(now, expiresAtMs(ticket, now)) + MONITOR_TIMEOUT_MS;\n }\n \n /** The part of a WebSocket --follow uses: the platform's own, or a test's. */"},{"path":"client/test/news-stream.test.ts","added":6,"removed":0,"diff":"--- a/client/test/news-stream.test.ts\n+++ b/client/test/news-stream.test.ts\n@@ -3,6 +3,7 @@\n import assert from \"node:assert/strict\";\n import { test } from \"node:test\";\n import {\n+\texpiresAtMs,\n \ttype FollowDeps,\n \tfollow,\n \tisRefusal,\n@@ -41,6 +42,11 @@\n \tassert.match(text[0]!, /within 45 seconds/);\n \tassert.match(text[0]!, /run abso news --stream again/);\n \tassert.deepEqual(JSON.parse(text[1]!), args);\n+\t// The server sends the expiry as an ISO time (staging 1418); the countdown and the stream mark read it the same.\n+\tconst iso = { ...ticket(1), expiresAt: new Date(NOW + 60_000).toISOString() };\n+\tassert.match(streamText(iso, \"abso\", \"fe\", NOW + 15_000), /within 45 seconds/);\n+\tassert.equal(streamMarkUntil(iso, NOW), NOW + 60_000 + MONITOR_TIMEOUT_MS);\n+\tassert.equal(expiresAtMs({ ...ticket(1), expiresAt: \"soon\" }, NOW), NOW);\n });\n \n test(\"a refusal close stops --follow; any other close opens again, waiting 1 s doubling to a minute\", () => {"}],"ci":null}