mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 09:50:42 +00:00
fix(release): clean up one-shot gateway MCP runtimes
This commit is contained in:
@@ -121,6 +121,7 @@ while IFS='|' read -r label spec plugin_id source expectation surface_mode perso
|
||||
export KITCHEN_SINK_SOURCE="$source"
|
||||
export KITCHEN_SINK_SURFACE_MODE="$surface_mode"
|
||||
export KITCHEN_SINK_PERSONALITY="${personality:-}"
|
||||
export OPENCLAW_KITCHEN_SINK_PERSONALITY="${personality:-}"
|
||||
case "$expectation" in
|
||||
success)
|
||||
run_success_scenario
|
||||
|
||||
@@ -1212,6 +1212,21 @@ describe("gateway agent handler", () => {
|
||||
);
|
||||
});
|
||||
|
||||
it("forwards one-shot bundle MCP cleanup from agent RPC into the runner", async () => {
|
||||
primeMainAgentRun();
|
||||
mocks.agentCommand.mockClear();
|
||||
|
||||
await invokeAgent({
|
||||
message: "cleanup probe",
|
||||
sessionKey: "agent:main:subagent:cleanup-probe",
|
||||
idempotencyKey: "test-idem-agent-cleanup-bundle-mcp",
|
||||
cleanupBundleMcpOnRunEnd: true,
|
||||
});
|
||||
|
||||
const call = await waitForAgentCommandCall();
|
||||
expect(call.cleanupBundleMcpOnRunEnd).toBe(true);
|
||||
});
|
||||
|
||||
it.each(
|
||||
(["channel", "replyChannel"] as const).flatMap((field) =>
|
||||
(["heartbeat", "cron", "webhook"] as const).map((channel) => [field, channel] as const),
|
||||
|
||||
@@ -1373,6 +1373,7 @@ export const agentHandlers: GatewayRequestHandlers = {
|
||||
acpTurnSource: request.acpTurnSource,
|
||||
internalEvents: request.internalEvents,
|
||||
inputProvenance,
|
||||
cleanupBundleMcpOnRunEnd: request.cleanupBundleMcpOnRunEnd,
|
||||
abortSignal: activeRunAbort.controller.signal,
|
||||
// Internal-only: allow workspace override for spawned subagent runs.
|
||||
workspaceDir: resolveIngressWorkspaceOverrideForSpawnedRun({
|
||||
|
||||
@@ -108,6 +108,7 @@ describe("scripts/lib/plugin-prerelease-test-plan.mjs", () => {
|
||||
expect(script).toContain("scripts/e2e/lib/kitchen-sink-plugin/sweep.sh");
|
||||
expect(sweepScript).toContain('plugins install "$KITCHEN_SINK_SPEC"');
|
||||
expect(sweepScript).toContain("KITCHEN_SINK_PERSONALITY");
|
||||
expect(sweepScript).toContain("OPENCLAW_KITCHEN_SINK_PERSONALITY");
|
||||
expect(sweepScript).toContain('plugins uninstall "$KITCHEN_SINK_SPEC" --force');
|
||||
const successScenario = sweepScript.slice(
|
||||
sweepScript.indexOf("run_success_scenario()"),
|
||||
|
||||
Reference in New Issue
Block a user