diff --git a/pm-stack/aggregator/src/render.ts b/pm-stack/aggregator/src/render.ts index cb4a2a5926..ee256d7310 100644 --- a/pm-stack/aggregator/src/render.ts +++ b/pm-stack/aggregator/src/render.ts @@ -403,7 +403,10 @@ setTimeout(function () { if (!skel) return; var p = document.createElement("p"); p.className = "frag-failed"; - p.innerHTML = "the live view did not arrive — load the full page"; + var a = document.createElement("a"); + a.href = location.pathname + "?full=1"; + a.textContent = "load the full page"; + p.append("the live view did not arrive \u2014 ", a); skel.replaceWith(p); }); }, ${FRAG_WATCHDOG_MS}); diff --git a/pm-stack/aggregator/test/frag-watchdog-1503.test.ts b/pm-stack/aggregator/test/frag-watchdog-1503.test.ts index 007dde2347..fb52cc2732 100644 --- a/pm-stack/aggregator/test/frag-watchdog-1503.test.ts +++ b/pm-stack/aggregator/test/frag-watchdog-1503.test.ts @@ -2,6 +2,7 @@ import { describe, expect, test } from "bun:test"; import { fixtureSource } from "../src/sources/fixtures.ts"; import { FRAG_WATCHDOG_MS, + FRAG_WATCHDOG_SCRIPT, renderAttentionShell, renderBoardShell, renderOverviewShell, @@ -54,4 +55,36 @@ describe("shell fragment watchdog (#1503)", () => { expect(html).toContain("frag-failed"); expect(html.indexOf('class="today-health-strip"')).toBeLessThan(html.indexOf('class="skel"')); }); + + // #11410: the shells only asserted on strings, so a quoting bug that + // made the script unparseable shipped unnoticed. Parse and run it. + test("watchdog script parses and swaps a stalled skeleton for the notice", () => { + const body = FRAG_WATCHDOG_SCRIPT.replace(/^