From a60ff003fba4f0fbfcdefe19ab4c1ef24c404428 Mon Sep 17 00:00:00 2001 From: Peter Steinberger Date: Sat, 11 Apr 2026 18:31:06 +0100 Subject: [PATCH] test(parallels): stop gateway before npm update --- scripts/e2e/parallels-npm-update-smoke.sh | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/scripts/e2e/parallels-npm-update-smoke.sh b/scripts/e2e/parallels-npm-update-smoke.sh index 060f8b20f44..cd9c44e73dd 100755 --- a/scripts/e2e/parallels-npm-update-smoke.sh +++ b/scripts/e2e/parallels-npm-update-smoke.sh @@ -927,6 +927,11 @@ if [ -z "\${$API_KEY_ENV:-}" ]; then exit 1 fi cd "\$HOME" +# Stop the pre-update gateway before replacing the package. Otherwise the old +# host can observe new plugin metadata mid-update and abort config validation. +/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 /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. @@ -982,6 +987,11 @@ run_linux_update() { set -euo pipefail export HOME=/root cd "\$HOME" +# Stop the pre-update manual gateway before replacing the package. Otherwise +# the old host can observe new plugin metadata mid-update and abort validation. +pkill -9 -f openclaw-gateway || true +pkill -9 -f 'openclaw gateway run' || true +pkill -9 -f 'openclaw.mjs gateway' || true 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.