fix(release): clean up one-shot gateway MCP runtimes · openclaw/openclaw@b0cf761
steipete
·
2026-05-02
·
via Recent Commits to openclaw:main
File tree
scripts/e2e/lib/kitchen-sink-plugin
src/gateway/server-methods
| Original file line number | Diff line number | Diff line change |
|---|
@@ -121,6 +121,7 @@ while IFS='|' read -r label spec plugin_id source expectation surface_mode perso
|
121 | 121 | export KITCHEN_SINK_SOURCE="$source" |
122 | 122 | export KITCHEN_SINK_SURFACE_MODE="$surface_mode" |
123 | 123 | export KITCHEN_SINK_PERSONALITY="${personality:-}" |
| 124 | +export OPENCLAW_KITCHEN_SINK_PERSONALITY="${personality:-}" |
124 | 125 | case "$expectation" in |
125 | 126 | success) |
126 | 127 | run_success_scenario |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -1212,6 +1212,21 @@ describe("gateway agent handler", () => {
|
1212 | 1212 | ); |
1213 | 1213 | }); |
1214 | 1214 | |
| 1215 | +it("forwards one-shot bundle MCP cleanup from agent RPC into the runner", async () => { |
| 1216 | +primeMainAgentRun(); |
| 1217 | +mocks.agentCommand.mockClear(); |
| 1218 | + |
| 1219 | +await invokeAgent({ |
| 1220 | +message: "cleanup probe", |
| 1221 | +sessionKey: "agent:main:subagent:cleanup-probe", |
| 1222 | +idempotencyKey: "test-idem-agent-cleanup-bundle-mcp", |
| 1223 | +cleanupBundleMcpOnRunEnd: true, |
| 1224 | +}); |
| 1225 | + |
| 1226 | +const call = await waitForAgentCommandCall(); |
| 1227 | +expect(call.cleanupBundleMcpOnRunEnd).toBe(true); |
| 1228 | +}); |
| 1229 | + |
1215 | 1230 | it.each( |
1216 | 1231 | (["channel", "replyChannel"] as const).flatMap((field) => |
1217 | 1232 | (["heartbeat", "cron", "webhook"] as const).map((channel) => [field, channel] as const), |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -1373,6 +1373,7 @@ export const agentHandlers: GatewayRequestHandlers = {
|
1373 | 1373 | acpTurnSource: request.acpTurnSource, |
1374 | 1374 | internalEvents: request.internalEvents, |
1375 | 1375 | inputProvenance, |
| 1376 | +cleanupBundleMcpOnRunEnd: request.cleanupBundleMcpOnRunEnd, |
1376 | 1377 | abortSignal: activeRunAbort.controller.signal, |
1377 | 1378 | // Internal-only: allow workspace override for spawned subagent runs. |
1378 | 1379 | workspaceDir: resolveIngressWorkspaceOverrideForSpawnedRun({ |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -108,6 +108,7 @@ describe("scripts/lib/plugin-prerelease-test-plan.mjs", () => {
|
108 | 108 | expect(script).toContain("scripts/e2e/lib/kitchen-sink-plugin/sweep.sh"); |
109 | 109 | expect(sweepScript).toContain('plugins install "$KITCHEN_SINK_SPEC"'); |
110 | 110 | expect(sweepScript).toContain("KITCHEN_SINK_PERSONALITY"); |
| 111 | +expect(sweepScript).toContain("OPENCLAW_KITCHEN_SINK_PERSONALITY"); |
111 | 112 | expect(sweepScript).toContain('plugins uninstall "$KITCHEN_SINK_SPEC" --force'); |
112 | 113 | const successScenario = sweepScript.slice( |
113 | 114 | sweepScript.indexOf("run_success_scenario()"), |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。