



























@@ -23,6 +23,10 @@ const COMMAND_TIMEOUT_MS = readPositiveInt(
2323process.env.OPENCLAW_KITCHEN_SINK_RPC_COMMAND_MS,
2424180000,
2525);
26+const INSTALL_TIMEOUT_MS = readPositiveInt(
27+process.env.OPENCLAW_KITCHEN_SINK_RPC_INSTALL_MS,
28+Math.max(COMMAND_TIMEOUT_MS, 600000),
29+);
2630const RPC_TIMEOUT_MS = readPositiveInt(process.env.OPENCLAW_KITCHEN_SINK_RPC_CALL_MS, 60000);
2731const MAX_RSS_MIB = readPositiveInt(process.env.OPENCLAW_KITCHEN_SINK_MAX_RSS_MIB, 2048);
2832const DEFAULT_PORT = 19000 + Math.floor(Math.random() * 1000);
@@ -90,7 +94,9 @@ function runCommand(command, args, options = {}) {
9094let stdout = "";
9195let stderr = "";
9296const timeoutMs = options.timeoutMs ?? COMMAND_TIMEOUT_MS;
97+let timedOut = false;
9398const timer = setTimeout(() => {
99+timedOut = true;
94100child.kill("SIGTERM");
95101setTimeout(() => child.kill("SIGKILL"), 2000).unref();
96102}, timeoutMs);
@@ -111,9 +117,12 @@ function runCommand(command, args, options = {}) {
111117return;
112118}
113119const detail = [stdout, stderr].filter(Boolean).join("\n").trim();
120+const failure = timedOut
121+ ? `timed out after ${timeoutMs}ms`
122+ : `failed with ${signal || status}`;
114123reject(
115124new Error(
116-`${command} ${args.join(" ")} failed with ${signal || status}${detail ? `\n${tailText(detail)}` : ""}`,
125+`${command} ${args.join(" ")} ${failure}${detail ? `\n${tailText(detail)}` : ""}`,
117126),
118127);
119128});
@@ -571,7 +580,9 @@ async function main() {
571580const logPath = path.join(root, "gateway.log");
572581573582console.log(`Kitchen Sink RPC walk using ${PLUGIN_SPEC} via ${runner.label}`);
574-await runOpenClaw(runner, ["plugins", "install", PLUGIN_SPEC], env, { timeoutMs: 240000 });
583+await runOpenClaw(runner, ["plugins", "install", PLUGIN_SPEC], env, {
584+timeoutMs: INSTALL_TIMEOUT_MS,
585+});
575586configureKitchenSink(env, port);
576587await runOpenClaw(runner, ["plugins", "enable", PLUGIN_ID], env, { timeoutMs: 60000 });
577588const inspect = parseJsonOutput(
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。