@firstpick/pi-package-webui 0.7.6 → 0.7.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +60 -4
- package/bin/pi-webui-rpc-supervisor.mjs +612 -0
- package/bin/pi-webui.mjs +1051 -95
- package/lib/WEBUI_TUI_NATIVE_PARITY.json +13 -0
- package/lib/rpc-supervisor-client.mjs +317 -0
- package/lib/rpc-supervisor-protocol.mjs +245 -0
- package/lib/rpc-supervisor-state.mjs +165 -0
- package/lib/trust-boundaries.mjs +1 -0
- package/package.json +4 -4
- package/public/app.js +1986 -170
- package/public/index.html +388 -25
- package/public/issue-bot-client.mjs +344 -0
- package/public/issue-wizard-state.mjs +443 -0
- package/public/service-worker.js +8 -1
- package/public/styles.css +578 -52
- package/public/subagent-gate-visibility.mjs +36 -0
- package/public/workflow-status-stack.mjs +69 -0
- package/tests/app-runner-process-tree-harness.test.mjs +37 -3
- package/tests/boot-failure-diagnostics.test.mjs +180 -0
- package/tests/completion-signal-contract.test.mjs +156 -0
- package/tests/cwd-footer-reliability-static.test.mjs +107 -0
- package/tests/durable-rpc-supervisor-harness.test.mjs +275 -0
- package/tests/fast-mode-client-static.test.mjs +2 -2
- package/tests/fixtures/fake-pi.mjs +90 -6
- package/tests/footer-context-contrast-static.test.mjs +10 -0
- package/tests/git-panel-file-preview-static.test.mjs +221 -0
- package/tests/git-panel-render-stability-static.test.mjs +11 -1
- package/tests/http-endpoints-harness.test.mjs +458 -33
- package/tests/issue-bot-client.test.mjs +135 -0
- package/tests/issue-wizard-state.test.mjs +126 -0
- package/tests/mobile-static.test.mjs +79 -16
- package/tests/native-parity-harness.test.mjs +2 -1
- package/tests/native-parity.test.mjs +13 -2
- package/tests/numpad-decimal-input-static.test.mjs +128 -0
- package/tests/open-issue-wizard-static.test.mjs +75 -0
- package/tests/prompt-routing-input-clear-static.test.mjs +34 -0
- package/tests/prompt-routing-tab-status.test.mjs +108 -0
- package/tests/rpc-supervisor-host.test.mjs +408 -0
- package/tests/rpc-supervisor-protocol.test.mjs +93 -0
- package/tests/rpc-supervisor-state.test.mjs +62 -0
- package/tests/run-all.mjs +4 -1
- package/tests/streaming-ui-coupling.test.mjs +18 -2
- package/tests/subagent-gate-visibility.test.mjs +66 -0
- package/tests/subagent-launch-slots-static.test.mjs +1 -1
- package/tests/subagents-helper.test.mjs +136 -0
- package/tests/terminal-tab-workspace-static.test.mjs +99 -0
- package/tests/workflow-status-stack.test.mjs +87 -0
- package/webui-rpc-helper.mjs +160 -2
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
export const SUBAGENT_GATE_RETENTION_MS = 30_000;
|
|
2
|
+
|
|
3
|
+
export function subagentGateKey(tabId, gateId) {
|
|
4
|
+
const normalizedTabId = String(tabId || "").trim();
|
|
5
|
+
const normalizedGateId = String(gateId || "").trim();
|
|
6
|
+
return normalizedTabId && normalizedGateId ? `${normalizedTabId}:${normalizedGateId}` : "";
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export function subagentGateIsTerminal(gate) {
|
|
10
|
+
return gate?.status !== "running";
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export function visibleSubagentGates(tab, dismissedGateKeys, now = Date.now(), retentionMs = SUBAGENT_GATE_RETENTION_MS) {
|
|
14
|
+
const gates = Array.isArray(tab?.gates) ? tab.gates : [];
|
|
15
|
+
return gates.filter((gate) => {
|
|
16
|
+
if (!subagentGateIsTerminal(gate)) return true;
|
|
17
|
+
const key = subagentGateKey(tab?.tabId, gate?.id);
|
|
18
|
+
if (key && dismissedGateKeys?.has?.(key)) return false;
|
|
19
|
+
const endedAt = Number(gate?.endedAt ?? gate?.updatedAt);
|
|
20
|
+
return !Number.isFinite(endedAt) || Math.max(0, now - endedAt) < retentionMs;
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export function pruneDismissedSubagentGateKeys(tabs, dismissedGateKeys) {
|
|
25
|
+
if (!dismissedGateKeys?.size) return;
|
|
26
|
+
const liveKeys = new Set();
|
|
27
|
+
for (const tab of Array.isArray(tabs) ? tabs : []) {
|
|
28
|
+
for (const gate of Array.isArray(tab?.gates) ? tab.gates : []) {
|
|
29
|
+
const key = subagentGateKey(tab?.tabId, gate?.id);
|
|
30
|
+
if (key) liveKeys.add(key);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
for (const key of dismissedGateKeys) {
|
|
34
|
+
if (!liveKeys.has(key)) dismissedGateKeys.delete(key);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
const WORKFLOW_STATUS_TOOL_NAME = "workflow_status";
|
|
2
|
+
|
|
3
|
+
export function isCompletedWorkflowStatusExecution(message) {
|
|
4
|
+
if (message?.role !== "toolExecution") return false;
|
|
5
|
+
const name = String(message.toolName || message.name || "");
|
|
6
|
+
return name === WORKFLOW_STATUS_TOOL_NAME && !message.live && !message.isPartial && message.result !== undefined && message.result !== null;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
function workflowStatusStackKey(items) {
|
|
10
|
+
const first = items[0] || {};
|
|
11
|
+
const toolCallId = String(first.message?.toolCallId ?? "").trim();
|
|
12
|
+
const id = toolCallId || (first.messageIndex !== undefined ? `m:${first.messageIndex}` : first.order !== undefined ? `o:${first.order}` : "first");
|
|
13
|
+
return `workflow-status-stack:${id}`;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
export function groupConsecutiveWorkflowStatusItems(items) {
|
|
17
|
+
const grouped = [];
|
|
18
|
+
let pending = [];
|
|
19
|
+
|
|
20
|
+
const flush = () => {
|
|
21
|
+
if (pending.length === 1) {
|
|
22
|
+
grouped.push(pending[0]);
|
|
23
|
+
} else if (pending.length > 1) {
|
|
24
|
+
const first = pending[0];
|
|
25
|
+
const latest = pending.at(-1);
|
|
26
|
+
const updates = pending.map((item) => item.message);
|
|
27
|
+
grouped.push({
|
|
28
|
+
...first,
|
|
29
|
+
message: {
|
|
30
|
+
role: "workflowStatusStack",
|
|
31
|
+
title: `workflow_status · ${updates.length} updates`,
|
|
32
|
+
timestamp: latest.message?.timestamp || first.message?.timestamp,
|
|
33
|
+
content: latest.message?.result?.content,
|
|
34
|
+
workflowStatusUpdates: updates,
|
|
35
|
+
isError: updates.some((update) => update?.isError || update?.result?.isError),
|
|
36
|
+
},
|
|
37
|
+
transcriptKey: workflowStatusStackKey(pending),
|
|
38
|
+
});
|
|
39
|
+
}
|
|
40
|
+
pending = [];
|
|
41
|
+
};
|
|
42
|
+
|
|
43
|
+
for (const item of items || []) {
|
|
44
|
+
if (isCompletedWorkflowStatusExecution(item?.message)) pending.push(item);
|
|
45
|
+
else {
|
|
46
|
+
flush();
|
|
47
|
+
grouped.push(item);
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
flush();
|
|
51
|
+
return grouped;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export function workflowStatusSnapshot(text) {
|
|
55
|
+
const fields = {};
|
|
56
|
+
const lines = String(text || "").split(/\r?\n/).map((line) => line.trim()).filter(Boolean);
|
|
57
|
+
for (const line of lines) {
|
|
58
|
+
const match = /^(Workflow|Run|Status|Tasks):\s*(.+)$/i.exec(line);
|
|
59
|
+
if (match) fields[match[1].toLowerCase()] = match[2].trim();
|
|
60
|
+
}
|
|
61
|
+
const fallback = lines[0] || "No workflow status details were returned.";
|
|
62
|
+
return {
|
|
63
|
+
workflow: fields.workflow || "",
|
|
64
|
+
run: fields.run || "",
|
|
65
|
+
status: fields.status || "",
|
|
66
|
+
tasks: fields.tasks || "",
|
|
67
|
+
fallback: fallback.length > 180 ? `${fallback.slice(0, 179)}…` : fallback,
|
|
68
|
+
};
|
|
69
|
+
}
|
|
@@ -6,6 +6,8 @@ import path from "node:path";
|
|
|
6
6
|
import { setTimeout as delay } from "node:timers/promises";
|
|
7
7
|
import { dirname, join } from "node:path";
|
|
8
8
|
import { fileURLToPath } from "node:url";
|
|
9
|
+
import { connectRpcSupervisor } from "../lib/rpc-supervisor-client.mjs";
|
|
10
|
+
import { readSupervisorState, supervisorPaths } from "../lib/rpc-supervisor-state.mjs";
|
|
9
11
|
|
|
10
12
|
const root = join(dirname(fileURLToPath(import.meta.url)), "..");
|
|
11
13
|
const serverScript = join(root, "bin", "pi-webui.mjs");
|
|
@@ -53,6 +55,8 @@ function killFixtureProcess(pid) {
|
|
|
53
55
|
}
|
|
54
56
|
|
|
55
57
|
const cwd = await mkdtemp(path.join(tmpdir(), "pi-webui-app-runner-tree-"));
|
|
58
|
+
const agentDir = path.join(cwd, "agent");
|
|
59
|
+
const supervisorStatePaths = await supervisorPaths({ agentDir, port });
|
|
56
60
|
const settingsFile = path.join(cwd, "webui-settings.json");
|
|
57
61
|
await chmod(fakePi, 0o755);
|
|
58
62
|
await writeFile(path.join(cwd, "tree-child.mjs"), "setInterval(() => {}, 1000);\n");
|
|
@@ -72,27 +76,37 @@ const server = spawn(process.execPath, [serverScript, "--cwd", cwd, "--host", "1
|
|
|
72
76
|
stdio: ["ignore", "pipe", "pipe"],
|
|
73
77
|
env: {
|
|
74
78
|
...process.env,
|
|
79
|
+
PI_CODING_AGENT_DIR: agentDir,
|
|
75
80
|
PI_WEBUI_SETTINGS_FILE: settingsFile,
|
|
76
81
|
PI_WEBUI_APP_RUNNER_PTY: "off",
|
|
77
82
|
},
|
|
78
83
|
windowsHide: true,
|
|
79
84
|
});
|
|
80
85
|
let serverOutput = "";
|
|
86
|
+
let piPid = 0;
|
|
87
|
+
let supervisorPid = 0;
|
|
81
88
|
let runnerPid = 0;
|
|
82
89
|
let treeChildPid = 0;
|
|
83
90
|
server.stdout.on("data", (chunk) => { serverOutput += String(chunk); });
|
|
84
91
|
server.stderr.on("data", (chunk) => { serverOutput += String(chunk); });
|
|
85
92
|
|
|
86
93
|
try {
|
|
87
|
-
await waitFor("server health", async () => {
|
|
94
|
+
const health = await waitFor("server health", async () => {
|
|
88
95
|
if (server.exitCode !== null) return false;
|
|
89
96
|
try {
|
|
90
|
-
const
|
|
91
|
-
return
|
|
97
|
+
const response = await request("/api/health", { timeoutMs: 1_000 });
|
|
98
|
+
return response.status === 200 && response.body?.ok === true ? response : false;
|
|
92
99
|
} catch {
|
|
93
100
|
return false;
|
|
94
101
|
}
|
|
95
102
|
}, { attempts: 100, intervalMs: 120 });
|
|
103
|
+
piPid = Number(health.body?.piPid) || 0;
|
|
104
|
+
assert.ok(piPid > 0, `startup fake Pi PID should be available, output:\n${serverOutput}`);
|
|
105
|
+
if (health.body?.rpcSupervisor?.enabled === true) {
|
|
106
|
+
const state = await waitFor("isolated supervisor state", () => readSupervisorState(supervisorStatePaths));
|
|
107
|
+
supervisorPid = Number(state.pid) || 0;
|
|
108
|
+
assert.ok(supervisorPid > 0, "isolated supervisor state should identify its process");
|
|
109
|
+
}
|
|
96
110
|
|
|
97
111
|
const tabsResponse = await request("/api/tabs");
|
|
98
112
|
const tabId = tabsResponse.body?.data?.tabs?.[0]?.id || tabsResponse.body?.tabs?.[0]?.id;
|
|
@@ -149,6 +163,11 @@ try {
|
|
|
149
163
|
await request("/api/shutdown", { method: "POST" }).catch(() => undefined);
|
|
150
164
|
for (let attempt = 0; attempt < 50 && server.exitCode === null; attempt += 1) await delay(100);
|
|
151
165
|
assert.notEqual(server.exitCode, null, "server should exit after /api/shutdown");
|
|
166
|
+
await waitFor("fake Pi teardown", () => !isProcessRunning(piPid));
|
|
167
|
+
if (supervisorPid > 0) await waitFor("supervisor teardown", () => !isProcessRunning(supervisorPid));
|
|
168
|
+
await waitFor("isolated supervisor state cleanup", async () => (await readSupervisorState(supervisorStatePaths)) === null);
|
|
169
|
+
assert.equal(isProcessRunning(piPid), false, "server teardown must not leave its fake Pi running");
|
|
170
|
+
assert.equal(isProcessRunning(supervisorPid), false, "server teardown must not leave its supervisor running");
|
|
152
171
|
console.log("app-runner-process-tree-harness.test.mjs passed");
|
|
153
172
|
} finally {
|
|
154
173
|
if (server.exitCode === null) {
|
|
@@ -156,7 +175,22 @@ try {
|
|
|
156
175
|
for (let attempt = 0; attempt < 20 && server.exitCode === null; attempt += 1) await delay(100);
|
|
157
176
|
if (server.exitCode === null) server.kill("SIGKILL");
|
|
158
177
|
}
|
|
178
|
+
const remainingSupervisor = await readSupervisorState(supervisorStatePaths).catch(() => null);
|
|
179
|
+
if (remainingSupervisor) {
|
|
180
|
+
const cleanupClient = await connectRpcSupervisor({
|
|
181
|
+
agentDir,
|
|
182
|
+
port,
|
|
183
|
+
controllerId: "app-runner-process-tree-cleanup",
|
|
184
|
+
connectTimeoutMs: 1_000,
|
|
185
|
+
}).catch(() => null);
|
|
186
|
+
if (cleanupClient) {
|
|
187
|
+
try { await cleanupClient.shutdown(); } catch {}
|
|
188
|
+
cleanupClient.close();
|
|
189
|
+
}
|
|
190
|
+
}
|
|
159
191
|
killFixtureProcess(runnerPid);
|
|
160
192
|
killFixtureProcess(treeChildPid);
|
|
193
|
+
killFixtureProcess(piPid);
|
|
194
|
+
killFixtureProcess(supervisorPid);
|
|
161
195
|
await rm(cwd, { recursive: true, force: true });
|
|
162
196
|
}
|
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
import assert from "node:assert/strict";
|
|
2
|
+
import { readFile } from "node:fs/promises";
|
|
3
|
+
import { dirname, join } from "node:path";
|
|
4
|
+
import vm from "node:vm";
|
|
5
|
+
import { fileURLToPath } from "node:url";
|
|
6
|
+
|
|
7
|
+
const root = join(dirname(fileURLToPath(import.meta.url)), "..");
|
|
8
|
+
const [html, app, serviceWorker] = await Promise.all([
|
|
9
|
+
readFile(join(root, "public", "index.html"), "utf8"),
|
|
10
|
+
readFile(join(root, "public", "app.js"), "utf8"),
|
|
11
|
+
readFile(join(root, "public", "service-worker.js"), "utf8"),
|
|
12
|
+
]);
|
|
13
|
+
|
|
14
|
+
const loaderMatch = html.match(/<script id="webuiBootLoader"[^>]*>([\s\S]*?)<\/script>/);
|
|
15
|
+
assert.ok(loaderMatch, "index.html should contain the inline WebUI boot loader");
|
|
16
|
+
const loaderSource = loaderMatch[1];
|
|
17
|
+
|
|
18
|
+
class FakeElement {
|
|
19
|
+
constructor(values = {}) {
|
|
20
|
+
Object.assign(this, values);
|
|
21
|
+
this.listeners = new Map();
|
|
22
|
+
this.hidden ??= true;
|
|
23
|
+
this.value ??= "";
|
|
24
|
+
this.textContent ??= "";
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
addEventListener(name, listener) {
|
|
28
|
+
this.listeners.set(name, listener);
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
focus() {}
|
|
32
|
+
select() { this.selected = true; }
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
class FakeResponse {
|
|
36
|
+
constructor(url, status, { type = "text/plain", text = "", json = null } = {}) {
|
|
37
|
+
this.url = url;
|
|
38
|
+
this.status = status;
|
|
39
|
+
this.ok = status >= 200 && status < 300;
|
|
40
|
+
this._text = text;
|
|
41
|
+
this._json = json;
|
|
42
|
+
this.headers = { get: (name) => name.toLowerCase() === "content-type" ? type : null };
|
|
43
|
+
this.body = { cancel: async () => {} };
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
clone() { return new FakeResponse(this.url, this.status, { type: this.headers.get("content-type"), text: this._text, json: this._json }); }
|
|
47
|
+
async text() { return this._text; }
|
|
48
|
+
async json() { return this._json; }
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
function makeEnvironment({ importApp, stylesheetLoaded = true, stylesheetStatus = 200, workflowModuleStatus = 404 } = {}) {
|
|
52
|
+
const elements = {
|
|
53
|
+
panel: new FakeElement({ hidden: true }),
|
|
54
|
+
reason: new FakeElement(),
|
|
55
|
+
report: new FakeElement({ value: "Collecting diagnostics…" }),
|
|
56
|
+
copy: new FakeElement(),
|
|
57
|
+
reload: new FakeElement(),
|
|
58
|
+
copyStatus: new FakeElement(),
|
|
59
|
+
};
|
|
60
|
+
const styleLink = new FakeElement({ href: "http://127.0.0.1:31415/styles.css?v=85", sheet: stylesheetLoaded ? {} : null });
|
|
61
|
+
const listeners = new Map();
|
|
62
|
+
const timers = new Map();
|
|
63
|
+
let timerId = 0;
|
|
64
|
+
let copied = "";
|
|
65
|
+
let reloaded = false;
|
|
66
|
+
|
|
67
|
+
const location = {
|
|
68
|
+
href: "http://127.0.0.1:31415/?pin=SUPERSECRET#private",
|
|
69
|
+
origin: "http://127.0.0.1:31415",
|
|
70
|
+
reload() { reloaded = true; },
|
|
71
|
+
};
|
|
72
|
+
const window = {
|
|
73
|
+
location,
|
|
74
|
+
__PI_WEBUI_BOOT_IMPORT__: importApp,
|
|
75
|
+
addEventListener(name, listener) { listeners.set(name, listener); },
|
|
76
|
+
removeEventListener(name) { listeners.delete(name); },
|
|
77
|
+
};
|
|
78
|
+
const document = {
|
|
79
|
+
currentScript: new FakeElement({ dataset: { appSrc: "/app.js?v=92" } }),
|
|
80
|
+
readyState: "complete",
|
|
81
|
+
querySelector(selector) {
|
|
82
|
+
return {
|
|
83
|
+
"#webuiBootFailurePanel": elements.panel,
|
|
84
|
+
"#webuiBootFailureReason": elements.reason,
|
|
85
|
+
"#webuiBootFailureReport": elements.report,
|
|
86
|
+
"#copyWebuiBootFailureReportButton": elements.copy,
|
|
87
|
+
"#reloadWebuiAfterBootFailureButton": elements.reload,
|
|
88
|
+
"#webuiBootFailureCopyStatus": elements.copyStatus,
|
|
89
|
+
'link[rel="stylesheet"]': styleLink,
|
|
90
|
+
}[selector] || null;
|
|
91
|
+
},
|
|
92
|
+
execCommand() { return true; },
|
|
93
|
+
};
|
|
94
|
+
|
|
95
|
+
async function fetch(input) {
|
|
96
|
+
const url = String(input);
|
|
97
|
+
if (url.includes("/api/health")) return new FakeResponse(url, 200, { type: "application/json", json: { ok: true, webuiVersion: "0.7.6", remoteAuthPin: "1234" } });
|
|
98
|
+
if (url.includes("/app.js")) return new FakeResponse(url, 200, { type: "text/javascript", text: 'import "./workflow-status-stack.mjs";\nimport "./fast-output-live.mjs";' });
|
|
99
|
+
if (url.includes("workflow-status-stack.mjs")) return new FakeResponse(url, workflowModuleStatus, { type: workflowModuleStatus === 200 ? "text/javascript" : "application/json" });
|
|
100
|
+
if (url.includes("fast-output-live.mjs")) return new FakeResponse(url, 200, { type: "text/javascript" });
|
|
101
|
+
if (url.includes("styles.css")) return new FakeResponse(url, stylesheetStatus, { type: "text/css" });
|
|
102
|
+
return new FakeResponse(url, 404);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
const context = {
|
|
106
|
+
window,
|
|
107
|
+
document,
|
|
108
|
+
navigator: {
|
|
109
|
+
userAgent: "Boot diagnostics test browser",
|
|
110
|
+
clipboard: { async writeText(value) { copied = value; } },
|
|
111
|
+
},
|
|
112
|
+
fetch,
|
|
113
|
+
URL,
|
|
114
|
+
Error,
|
|
115
|
+
Date,
|
|
116
|
+
Promise,
|
|
117
|
+
console,
|
|
118
|
+
setTimeout(callback) { const id = ++timerId; timers.set(id, callback); return id; },
|
|
119
|
+
clearTimeout(id) { timers.delete(id); },
|
|
120
|
+
};
|
|
121
|
+
|
|
122
|
+
return {
|
|
123
|
+
context,
|
|
124
|
+
elements,
|
|
125
|
+
listeners,
|
|
126
|
+
timers,
|
|
127
|
+
copied: () => copied,
|
|
128
|
+
reloaded: () => reloaded,
|
|
129
|
+
};
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
async function settleAsyncWork() {
|
|
133
|
+
for (let index = 0; index < 8; index += 1) await new Promise((resolve) => setImmediate(resolve));
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
const missingModule = makeEnvironment({
|
|
137
|
+
importApp: async () => { throw new Error("Failed to fetch dynamically imported module: http://127.0.0.1:31415/workflow-status-stack.mjs?pin=SUPERSECRET"); },
|
|
138
|
+
});
|
|
139
|
+
vm.runInNewContext(loaderSource, missingModule.context, { filename: "webui-boot-loader.js" });
|
|
140
|
+
await settleAsyncWork();
|
|
141
|
+
assert.equal(missingModule.elements.panel.hidden, false, "a rejected app import should expose the boot-failure panel");
|
|
142
|
+
assert.match(missingModule.elements.report.value, /Pi Web UI startup failure/);
|
|
143
|
+
assert.match(missingModule.elements.report.value, /Diagnosis[\s\S]*Summary: Missing startup module: \/workflow-status-stack\.mjs \(HTTP 404\)\./, "the diagnosis should name the actual missing transitive import before the full checks list");
|
|
144
|
+
assert.match(missingModule.elements.report.value, /Likely cause: The backend is healthy, but the running server's static asset allowlist is out of sync with app\.js\./);
|
|
145
|
+
assert.match(missingModule.elements.report.value, /Browser note: a transitive import failure may be reported as app\.js/);
|
|
146
|
+
assert.match(missingModule.elements.report.value, /Failing checks[\s\S]*HTTP 404 application\/json/, "the report should isolate failing probes");
|
|
147
|
+
assert.match(missingModule.elements.report.value, /Recheck the failing asset: curl -i http:\/\/127\.0\.0\.1:31415\/workflow-status-stack\.mjs/);
|
|
148
|
+
assert.match(missingModule.elements.report.value, /backend health: HTTP 200 application\/json \(ok=true, webuiVersion=0\.7\.6\)/);
|
|
149
|
+
assert.equal(missingModule.elements.reason.textContent, "Missing startup module: /workflow-status-stack.mjs (HTTP 404).", "the visible summary should expose the diagnosed file without requiring report inspection");
|
|
150
|
+
assert.match(missingModule.elements.report.value, /\/webui-status detailed/);
|
|
151
|
+
assert.doesNotMatch(missingModule.elements.report.value, /SUPERSECRET|remoteAuthPin|1234/, "diagnostics must omit URL secrets and unselected health fields");
|
|
152
|
+
await missingModule.elements.copy.listeners.get("click")();
|
|
153
|
+
assert.equal(missingModule.copied(), missingModule.elements.report.value, "Copy troubleshooting report should copy the complete generated report");
|
|
154
|
+
assert.equal(missingModule.elements.copyStatus.textContent, "Troubleshooting report copied.");
|
|
155
|
+
missingModule.elements.reload.listeners.get("click")();
|
|
156
|
+
assert.equal(missingModule.reloaded(), true, "Reload page should remain available without app.js");
|
|
157
|
+
|
|
158
|
+
const successfulBoot = makeEnvironment({ importApp: async () => ({}) });
|
|
159
|
+
vm.runInNewContext(loaderSource, successfulBoot.context, { filename: "webui-boot-loader.js" });
|
|
160
|
+
await settleAsyncWork();
|
|
161
|
+
assert.equal(successfulBoot.elements.panel.hidden, true, "a successful app import should keep the failure panel hidden");
|
|
162
|
+
assert.equal(successfulBoot.timers.size, 0, "successful startup should cancel the watchdog");
|
|
163
|
+
assert.equal(successfulBoot.listeners.has("error"), false, "successful startup should remove temporary global error capture");
|
|
164
|
+
|
|
165
|
+
const stylesheetFailure = makeEnvironment({ importApp: async () => ({}), stylesheetLoaded: false, stylesheetStatus: 404, workflowModuleStatus: 200 });
|
|
166
|
+
vm.runInNewContext(loaderSource, stylesheetFailure.context, { filename: "webui-boot-loader.js" });
|
|
167
|
+
await settleAsyncWork();
|
|
168
|
+
assert.equal(stylesheetFailure.elements.panel.hidden, false, "a missing critical stylesheet should expose the boot-failure panel");
|
|
169
|
+
assert.match(stylesheetFailure.elements.report.value, /Critical stylesheet returned HTTP 404/);
|
|
170
|
+
|
|
171
|
+
const startupModuleNames = [...new Set([...app.matchAll(/(?:\bfrom\s+|\bimport\s*(?:\(\s*)?)["']\.\/([^"'?]+)(?:\?[^"']*)?["']/g)].map((match) => match[1]))];
|
|
172
|
+
assert.ok(startupModuleNames.length >= 1, "the startup-module invariant should discover app.js imports");
|
|
173
|
+
for (const moduleName of startupModuleNames) {
|
|
174
|
+
assert.ok(serviceWorker.includes(`"/${moduleName}"`), `the PWA app shell should include every app.js startup module: ${moduleName}`);
|
|
175
|
+
}
|
|
176
|
+
assert.match(serviceWorker, /pi-webui-pwa-v\d+/, "the app-shell cache should retain a versioned identity");
|
|
177
|
+
assert.ok(html.indexOf('id="webuiBootLoader"') < html.indexOf("/app.js?v=92"), "the inline loader should own app module startup");
|
|
178
|
+
assert.doesNotMatch(html, /<script type="module" src="\/app\.js/, "the app module should not bypass the guarded loader");
|
|
179
|
+
|
|
180
|
+
console.log("boot-failure-diagnostics.test.mjs passed");
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
import assert from "node:assert/strict";
|
|
2
|
+
import vm from "node:vm";
|
|
3
|
+
import { readFile } from "node:fs/promises";
|
|
4
|
+
import { dirname, join } from "node:path";
|
|
5
|
+
import { fileURLToPath } from "node:url";
|
|
6
|
+
|
|
7
|
+
const root = join(dirname(fileURLToPath(import.meta.url)), "..");
|
|
8
|
+
const server = await readFile(join(root, "bin", "pi-webui.mjs"), "utf8");
|
|
9
|
+
const app = await readFile(join(root, "public", "app.js"), "utf8");
|
|
10
|
+
|
|
11
|
+
function functionSource(source, name) {
|
|
12
|
+
const start = source.indexOf(`function ${name}(`);
|
|
13
|
+
assert.ok(start >= 0, `${name} should exist`);
|
|
14
|
+
const next = source.slice(start + 1).match(/\n(?:async )?function [A-Za-z0-9_$]+\(/);
|
|
15
|
+
const end = next ? start + 1 + next.index : source.length;
|
|
16
|
+
return source.slice(start, end);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
const context = vm.createContext({ console });
|
|
20
|
+
vm.runInContext(`
|
|
21
|
+
const TAB_ACTIVITY_IDLE_RECONCILE_GRACE_MS = 1200;
|
|
22
|
+
function pendingExtensionUiRequests() { return []; }
|
|
23
|
+
function patchTabState(tab, patch) { tab.lastState = { ...(tab.lastState || {}), ...patch }; }
|
|
24
|
+
function rememberTabState(tab, state) { tab.lastState = state; }
|
|
25
|
+
|
|
26
|
+
${functionSource(server, "createTabActivity")}
|
|
27
|
+
${functionSource(server, "tabActivitySnapshot")}
|
|
28
|
+
${functionSource(server, "markTabWorking")}
|
|
29
|
+
${functionSource(server, "markTabDone")}
|
|
30
|
+
${functionSource(server, "markTabIdle")}
|
|
31
|
+
${functionSource(server, "stateHasVisibleWork")}
|
|
32
|
+
${functionSource(server, "activityRecentlyStarted")}
|
|
33
|
+
${functionSource(server, "reconcileTabActivityFromState")}
|
|
34
|
+
${functionSource(server, "updateTabActivityFromEvent")}
|
|
35
|
+
|
|
36
|
+
globalThis.activityContract = {
|
|
37
|
+
createTab() { return { activity: createTabActivity(), lastState: {} }; },
|
|
38
|
+
event(tab, event) { return updateTabActivityFromEvent(tab, event); },
|
|
39
|
+
submit(tab, timestamp) { markTabWorking(tab, timestamp); return tabActivitySnapshot(tab); },
|
|
40
|
+
start(tab, timestamp) { markTabWorking(tab, timestamp, { runStarted: true }); return tabActivitySnapshot(tab); },
|
|
41
|
+
reconcile(tab, state, timestamp) { return reconcileTabActivityFromState(tab, state, timestamp); },
|
|
42
|
+
};
|
|
43
|
+
`, context);
|
|
44
|
+
|
|
45
|
+
const contract = context.activityContract;
|
|
46
|
+
const tab = contract.createTab();
|
|
47
|
+
assert.equal(tab.activity.completionSerial, 0);
|
|
48
|
+
assert.equal(tab.activity.runStarted, false);
|
|
49
|
+
|
|
50
|
+
contract.event(tab, { type: "agent_start" });
|
|
51
|
+
assert.equal(tab.activity.isWorking, true);
|
|
52
|
+
assert.equal(tab.activity.runStarted, true);
|
|
53
|
+
assert.equal(tab.lastState.isStreaming, true);
|
|
54
|
+
|
|
55
|
+
contract.event(tab, { type: "agent_end" });
|
|
56
|
+
assert.equal(tab.activity.isWorking, true, "agent_end is only a low-level run boundary");
|
|
57
|
+
assert.equal(tab.activity.completionSerial, 0, "agent_end must not create a completion");
|
|
58
|
+
assert.equal(tab.lastState.isStreaming, true, "agent_end must not expose an idle window before continuation");
|
|
59
|
+
|
|
60
|
+
contract.event(tab, { type: "agent_settled" });
|
|
61
|
+
assert.equal(tab.activity.isWorking, false);
|
|
62
|
+
assert.equal(tab.activity.status, "done");
|
|
63
|
+
assert.equal(tab.activity.completionSerial, 1, "settlement should create exactly one completion");
|
|
64
|
+
assert.equal(tab.lastState.isStreaming, false);
|
|
65
|
+
|
|
66
|
+
contract.event(tab, { type: "agent_settled" });
|
|
67
|
+
assert.equal(tab.activity.status, "done", "duplicate settlement should preserve the completed state");
|
|
68
|
+
assert.equal(tab.activity.completionSerial, 1, "duplicate settlement must be idempotent");
|
|
69
|
+
|
|
70
|
+
const handledPromptTab = contract.createTab();
|
|
71
|
+
contract.submit(handledPromptTab, "2020-01-01T00:00:00.000Z");
|
|
72
|
+
contract.reconcile(handledPromptTab, { isStreaming: false, isCompacting: false, pendingMessageCount: 0 }, "2020-01-01T00:00:02.000Z");
|
|
73
|
+
assert.equal(handledPromptTab.activity.status, "idle", "a handled prompt without agent_start should return to idle");
|
|
74
|
+
assert.equal(handledPromptTab.activity.completionSerial, 0, "a handled prompt must not look completed");
|
|
75
|
+
|
|
76
|
+
const missedSettlementTab = contract.createTab();
|
|
77
|
+
contract.start(missedSettlementTab, "2020-01-01T00:00:00.000Z");
|
|
78
|
+
contract.reconcile(missedSettlementTab, { isStreaming: false, isCompacting: false, pendingMessageCount: 0 }, "2020-01-01T00:00:02.000Z");
|
|
79
|
+
assert.equal(missedSettlementTab.activity.completionSerial, 1, "authoritative idle may recover a missed settlement only after a real start");
|
|
80
|
+
|
|
81
|
+
const compactionTab = contract.createTab();
|
|
82
|
+
contract.event(compactionTab, { type: "compaction_start" });
|
|
83
|
+
contract.event(compactionTab, { type: "compaction_end" });
|
|
84
|
+
assert.equal(compactionTab.activity.status, "idle");
|
|
85
|
+
assert.equal(compactionTab.activity.completionSerial, 0, "standalone compaction must not emit agent completion");
|
|
86
|
+
|
|
87
|
+
const failedProcessTab = contract.createTab();
|
|
88
|
+
contract.event(failedProcessTab, { type: "agent_start" });
|
|
89
|
+
contract.event(failedProcessTab, { type: "pi_process_error" });
|
|
90
|
+
assert.equal(failedProcessTab.activity.status, "idle");
|
|
91
|
+
assert.equal(failedProcessTab.activity.completionSerial, 0, "a failed process must not masquerade as successful completion");
|
|
92
|
+
|
|
93
|
+
assert.match(app, /case "agent_settled":[\s\S]*?notifyAgentDone\(/, "the browser should notify only from settlement");
|
|
94
|
+
assert.doesNotMatch(functionSource(app, "handleInactiveTabEvent"), /event\.type === "agent_end"[\s\S]*?notifyAgentDone/, "background low-level run ends must not notify");
|
|
95
|
+
assert.doesNotMatch(app.match(/case "agent_end":[\s\S]*?case "message_start":/)?.[0] || "", /notifyAgentDone|isStreaming: false/, "active low-level run ends must not notify or look idle");
|
|
96
|
+
assert.match(functionSource(app, "markTabWorkingLocally"), /suppressPendingAgentDoneNotificationsForTab\(tabId\)/, "starting new work should cancel a delayed stale completion notification");
|
|
97
|
+
assert.match(functionSource(app, "queueAgentDoneBrowserNotification"), /activityForTab\(tab\)\.isWorking/, "the delayed notification should re-check that the tab is still idle");
|
|
98
|
+
|
|
99
|
+
const notificationContext = vm.createContext({ console, setTimeout, clearTimeout });
|
|
100
|
+
vm.runInContext(`
|
|
101
|
+
const AGENT_DONE_NOTIFICATION_RETRY_GRACE_MS = 5;
|
|
102
|
+
let tabs = [{ id: "tab-1", working: false }];
|
|
103
|
+
let promptRoutingTabs = new Set();
|
|
104
|
+
let autoRetryingTabs = new Set();
|
|
105
|
+
let pendingAgentDoneNotificationTimers = new Map();
|
|
106
|
+
let agentDoneNotificationKeys = new Set();
|
|
107
|
+
let shown = [];
|
|
108
|
+
function activityForTab(tab) { return { isWorking: tab?.working === true }; }
|
|
109
|
+
function isAutoRetryingTab(tabId) { return autoRetryingTabs.has(tabId); }
|
|
110
|
+
function showAgentDoneBrowserNotification(payload) { shown.push(payload); }
|
|
111
|
+
|
|
112
|
+
${functionSource(app, "clearPendingAgentDoneNotification")}
|
|
113
|
+
${functionSource(app, "queueAgentDoneBrowserNotification")}
|
|
114
|
+
|
|
115
|
+
globalThis.notificationContract = {
|
|
116
|
+
queue(key) { queueAgentDoneBrowserNotification({ key, tabId: "tab-1", title: "done", body: "done" }); },
|
|
117
|
+
setWorking(value) { tabs[0].working = value; },
|
|
118
|
+
setRouting(value) { if (value) promptRoutingTabs.add("tab-1"); else promptRoutingTabs.delete("tab-1"); },
|
|
119
|
+
setRetrying(value) { if (value) autoRetryingTabs.add("tab-1"); else autoRetryingTabs.delete("tab-1"); },
|
|
120
|
+
shown() { return shown.length; },
|
|
121
|
+
reset() {
|
|
122
|
+
for (const pending of pendingAgentDoneNotificationTimers.values()) clearTimeout(pending.timer);
|
|
123
|
+
pendingAgentDoneNotificationTimers.clear();
|
|
124
|
+
promptRoutingTabs.clear();
|
|
125
|
+
autoRetryingTabs.clear();
|
|
126
|
+
tabs[0].working = false;
|
|
127
|
+
shown = [];
|
|
128
|
+
},
|
|
129
|
+
};
|
|
130
|
+
`, notificationContext);
|
|
131
|
+
|
|
132
|
+
const notifications = notificationContext.notificationContract;
|
|
133
|
+
const waitForNotificationTimer = () => new Promise((resolve) => setTimeout(resolve, 20));
|
|
134
|
+
notifications.queue("idle");
|
|
135
|
+
await waitForNotificationTimer();
|
|
136
|
+
assert.equal(notifications.shown(), 1, "an idle settled tab should notify once");
|
|
137
|
+
|
|
138
|
+
notifications.reset();
|
|
139
|
+
notifications.queue("new-work");
|
|
140
|
+
notifications.setWorking(true);
|
|
141
|
+
await waitForNotificationTimer();
|
|
142
|
+
assert.equal(notifications.shown(), 0, "new work during the grace window should suppress the stale done notification");
|
|
143
|
+
|
|
144
|
+
notifications.reset();
|
|
145
|
+
notifications.queue("routing");
|
|
146
|
+
notifications.setRouting(true);
|
|
147
|
+
await waitForNotificationTimer();
|
|
148
|
+
assert.equal(notifications.shown(), 0, "prompt routing during the grace window should suppress the stale done notification");
|
|
149
|
+
|
|
150
|
+
notifications.reset();
|
|
151
|
+
notifications.queue("retry");
|
|
152
|
+
notifications.setRetrying(true);
|
|
153
|
+
await waitForNotificationTimer();
|
|
154
|
+
assert.equal(notifications.shown(), 0, "an automatic retry should suppress an intermediate done notification");
|
|
155
|
+
|
|
156
|
+
console.log("completion signal contract checks passed");
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
import assert from "node:assert/strict";
|
|
2
|
+
import { readFile } from "node:fs/promises";
|
|
3
|
+
import { dirname, join } from "node:path";
|
|
4
|
+
import { fileURLToPath } from "node:url";
|
|
5
|
+
|
|
6
|
+
const root = join(dirname(fileURLToPath(import.meta.url)), "..");
|
|
7
|
+
const [app, server, supervisor] = await Promise.all([
|
|
8
|
+
readFile(join(root, "public", "app.js"), "utf8"),
|
|
9
|
+
readFile(join(root, "bin", "pi-webui.mjs"), "utf8"),
|
|
10
|
+
readFile(join(root, "bin", "pi-webui-rpc-supervisor.mjs"), "utf8"),
|
|
11
|
+
]);
|
|
12
|
+
|
|
13
|
+
assert.match(
|
|
14
|
+
app,
|
|
15
|
+
/function pickCwd\(tab, initialCwd[\s\S]*?if \(pathPickerState\) \{[\s\S]*?working-directory picker is already open[\s\S]*?pathPickerSearchInput\.focus/,
|
|
16
|
+
"a duplicate cwd action should focus the existing picker and explain why no second picker opened",
|
|
17
|
+
);
|
|
18
|
+
assert.match(
|
|
19
|
+
app,
|
|
20
|
+
/async function changeActiveTabCwd\(\)[\s\S]*?title: "Changing working folder…"[\s\S]*?The existing working folder was kept[\s\S]*?surfaceRuntimeDiagnostic\("Working folder change failed", message\)/,
|
|
21
|
+
"cwd restarts should show immediate progress and transcript-visible failures with an atomicity explanation",
|
|
22
|
+
);
|
|
23
|
+
assert.match(
|
|
24
|
+
app,
|
|
25
|
+
/const changedTabId = response\.data\?\.tab\?\.id \|\| tab\.id;[\s\S]*?resetGitWorkflowForTab\(changedTabId\);[\s\S]*?clearGitFooterPayloadState\(changedTabId\);[\s\S]*?if \(!isCurrentTabContext\(tabContext\)\)/,
|
|
26
|
+
"a cwd change that finishes after a tab switch should invalidate that tab's old footer state",
|
|
27
|
+
);
|
|
28
|
+
|
|
29
|
+
assert.match(
|
|
30
|
+
app,
|
|
31
|
+
/function gitFooterFallbackMessage\(\)[\s\S]*?payloadState\?\.phase === "waiting"[\s\S]*?payloadState\?\.phase === "failed"[\s\S]*?payloadState\?\.phase === "idle"[\s\S]*?if \(extensionDetected\) return "Loading git footer status…"/,
|
|
32
|
+
"git footer fallback copy should distinguish active loading, terminal failure, cleared status, and discovery",
|
|
33
|
+
);
|
|
34
|
+
assert.match(
|
|
35
|
+
app,
|
|
36
|
+
/function waitForGitFooterPayloadSettlement\(tabContext, requestSerial\)[\s\S]*?gitFooterPayloadRequestSerialByTab\.get\(tabContext\.tabId\) !== requestSerial[\s\S]*?settleGitFooterPayload\(tabContext\.tabId, "failed"/,
|
|
37
|
+
"no-payload settlement should be bounded and reject stale request callbacks",
|
|
38
|
+
);
|
|
39
|
+
assert.match(
|
|
40
|
+
app,
|
|
41
|
+
/signal: AbortSignal\.timeout\(GIT_FOOTER_PAYLOAD_REQUEST_TIMEOUT_MS\)/,
|
|
42
|
+
"a hung footer refresh HTTP request should be bounded",
|
|
43
|
+
);
|
|
44
|
+
assert.match(
|
|
45
|
+
app,
|
|
46
|
+
/GIT_FOOTER_PAYLOAD_SETTLEMENT_TIMEOUT_MS[\s\S]*?Git footer refresh command is unavailable — reload to retry/,
|
|
47
|
+
"RPC command discovery should have a bounded loading window before actionable failure",
|
|
48
|
+
);
|
|
49
|
+
assert.match(
|
|
50
|
+
app,
|
|
51
|
+
/const validPayload = !!parseGitFooterWebuiPayloadRaw\(request\.statusText\);[\s\S]*?validPayload \? "ready" : "failed"/,
|
|
52
|
+
"a later valid live payload should recover failed or waiting footer state",
|
|
53
|
+
);
|
|
54
|
+
assert.match(
|
|
55
|
+
app,
|
|
56
|
+
/new Set\(\[\.\.\.gitFooterPayloadStateByTab\.keys\(\), \.\.\.gitFooterPayloadSettlementTimersByTab\.keys\(\), \.\.\.gitFooterPayloadRefreshInFlightByTab\]\)\) clearGitFooterPayloadState\(tabId\)/,
|
|
57
|
+
"feature toggles should clear footer state, timers, and in-flight markers",
|
|
58
|
+
);
|
|
59
|
+
|
|
60
|
+
assert.match(
|
|
61
|
+
server,
|
|
62
|
+
/async function updateTabCwd\(id, cwd\)[\s\S]*?cwdChangeInProgress[\s\S]*?makeHttpError\(409,[\s\S]*?performTabCwdUpdate/,
|
|
63
|
+
"overlapping cwd changes should be rejected per tab",
|
|
64
|
+
);
|
|
65
|
+
assert.match(
|
|
66
|
+
server,
|
|
67
|
+
/function scheduleSupervisorMetadataUpdate\(tab\)[\s\S]*?if \(tab\.cwdChangeInProgress\) return;[\s\S]*?updateMetadata\(supervisedTabMetadata\(tab\)\)/,
|
|
68
|
+
"stale full metadata writes should be deferred during cwd replacement",
|
|
69
|
+
);
|
|
70
|
+
assert.match(
|
|
71
|
+
server,
|
|
72
|
+
/async function performTabCwdUpdate\(tab, cwd\)[\s\S]*?!tab\.rpc\.supervisor\.isCurrentVersion\(\)[\s\S]*?Fully shut down Pi WebUI \(not Restart\)[\s\S]*?oldRpc\.replace\([\s\S]*?cwd: nextCwd[\s\S]*?tab\.cwd = nextCwd/,
|
|
73
|
+
"the server should reject stale detached supervisors and publish tab cwd only after replacement succeeds",
|
|
74
|
+
);
|
|
75
|
+
assert.match(
|
|
76
|
+
server,
|
|
77
|
+
/webui_cwd_change_failed[\s\S]*?makeHttpError\(502, `Could not restart/,
|
|
78
|
+
"replacement failures should produce an actionable SSE event and HTTP error",
|
|
79
|
+
);
|
|
80
|
+
|
|
81
|
+
assert.match(
|
|
82
|
+
supervisor,
|
|
83
|
+
/queueTabCommand\(tabId, operation\)[\s\S]*?tab\.mutationTail = admission\.catch[\s\S]*?return admission\.then\(\(\) => response\)[\s\S]*?case "command": return this\.queueTabCommand[\s\S]*?case "write": return this\.queueTabMutation/,
|
|
84
|
+
"commands should release their FIFO admission barrier before the full Pi response while writes remain serialized",
|
|
85
|
+
);
|
|
86
|
+
assert.doesNotMatch(
|
|
87
|
+
supervisor,
|
|
88
|
+
/async afterTabMutation\(/,
|
|
89
|
+
"commands must not chase a continuously moving mutation tail",
|
|
90
|
+
);
|
|
91
|
+
assert.match(
|
|
92
|
+
supervisor,
|
|
93
|
+
/async spawnChildCandidate\(child\)[\s\S]*?return \{ processChild, cwd, startedAt[\s\S]*?commitChild\(tab/,
|
|
94
|
+
"replacement children should be spawned privately before atomic publication",
|
|
95
|
+
);
|
|
96
|
+
assert.match(
|
|
97
|
+
supervisor,
|
|
98
|
+
/if \(tab\.child === processChild\) this\.handlePiLine[\s\S]*?text && tab\.child === processChild/,
|
|
99
|
+
"retired child stdout and stderr should be generation-fenced",
|
|
100
|
+
);
|
|
101
|
+
assert.match(
|
|
102
|
+
supervisor,
|
|
103
|
+
/const stopFailures = stopResults\.filter[\s\S]*?shutdown blocked by live child[\s\S]*?return false/,
|
|
104
|
+
"shutdown should retain ownership and state when a child cannot be stopped",
|
|
105
|
+
);
|
|
106
|
+
|
|
107
|
+
console.log("cwd-footer-reliability-static.test.mjs passed");
|