From f9b33b7d96acc9c8c1f306b182410075cb1c4e0a Mon Sep 17 00:00:00 2001 From: Peter Steinberger Date: Fri, 24 Apr 2026 03:23:10 +0100 Subject: [PATCH] fix: disable bundled plugins during Parallels update --- scripts/e2e/parallels-npm-update-smoke.sh | 9 +++++---- test/scripts/parallels-npm-update-smoke.test.ts | 5 +++++ 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/scripts/e2e/parallels-npm-update-smoke.sh b/scripts/e2e/parallels-npm-update-smoke.sh index 929c246a342..6e1164a71d7 100755 --- a/scripts/e2e/parallels-npm-update-smoke.sh +++ b/scripts/e2e/parallels-npm-update-smoke.sh @@ -679,6 +679,7 @@ function Invoke-OpenClawUpdateWithTimeout { $updateJob = Start-Job -ScriptBlock { param([string]$Path, [string]$Target) + $env:OPENCLAW_DISABLE_BUNDLED_PLUGINS = '1' $output = & $Path update --tag $Target --yes --json *>&1 [pscustomobject]@{ ExitCode = $LASTEXITCODE @@ -1433,7 +1434,7 @@ fs.writeFileSync(configPath, JSON.stringify(config, null, 2) + "\\n"); JS } stop_openclaw_gateway_processes() { - /opt/homebrew/bin/openclaw gateway stop >/dev/null 2>&1 || true + OPENCLAW_DISABLE_BUNDLED_PLUGINS=1 /opt/homebrew/bin/openclaw gateway stop >/dev/null 2>&1 || true /usr/bin/pkill -9 -f openclaw-gateway || true /usr/bin/pkill -9 -f 'openclaw gateway run' || true /usr/bin/pkill -9 -f 'openclaw.mjs gateway' || true @@ -1445,7 +1446,7 @@ stop_openclaw_gateway_processes() { # host can observe new plugin metadata mid-update and abort config validation. scrub_future_plugin_entries stop_openclaw_gateway_processes -/opt/homebrew/bin/openclaw update --tag "$update_target" --yes --json +OPENCLAW_DISABLE_BUNDLED_PLUGINS=1 /opt/homebrew/bin/openclaw update --tag "$update_target" --yes --json # Same-guest npm upgrades can leave the old gateway process holding the old # bundled plugin host version. Stop it before post-update config commands. stop_openclaw_gateway_processes @@ -1559,7 +1560,7 @@ fs.writeFileSync(configPath, JSON.stringify(config, null, 2) + "\\n"); JS } stop_openclaw_gateway_processes() { - openclaw gateway stop >/dev/null 2>&1 || true + OPENCLAW_DISABLE_BUNDLED_PLUGINS=1 openclaw gateway stop >/dev/null 2>&1 || true pkill -9 -f openclaw-gateway || true pkill -9 -f 'openclaw gateway run' || true pkill -9 -f 'openclaw.mjs gateway' || true @@ -1576,7 +1577,7 @@ stop_openclaw_gateway_processes() { # the old host can observe new plugin metadata mid-update and abort validation. scrub_future_plugin_entries stop_openclaw_gateway_processes -openclaw update --tag "$update_target" --yes --json +OPENCLAW_DISABLE_BUNDLED_PLUGINS=1 openclaw update --tag "$update_target" --yes --json # The fresh Linux lane starts a manual gateway; stop the old process before # post-update config validation sees mixed old-host/new-plugin metadata. stop_openclaw_gateway_processes diff --git a/test/scripts/parallels-npm-update-smoke.test.ts b/test/scripts/parallels-npm-update-smoke.test.ts index fba51f6c92a..46babc1889a 100644 --- a/test/scripts/parallels-npm-update-smoke.test.ts +++ b/test/scripts/parallels-npm-update-smoke.test.ts @@ -21,5 +21,10 @@ describe("parallels npm update smoke", () => { expect(script).toContain("delete entries.whatsapp"); expect(script).toContain("Remove-FuturePluginEntries\n Stop-OpenClawGatewayProcesses"); expect(script).toContain("scrub_future_plugin_entries\nstop_openclaw_gateway_processes"); + expect(script).toContain("$env:OPENCLAW_DISABLE_BUNDLED_PLUGINS = '1'"); + expect(script).toContain( + "OPENCLAW_DISABLE_BUNDLED_PLUGINS=1 /opt/homebrew/bin/openclaw update", + ); + expect(script).toContain("OPENCLAW_DISABLE_BUNDLED_PLUGINS=1 openclaw update"); }); });