@@ -21,7 +21,7 @@ baseline="${OPENCLAW_UPDATE_CORRUPT_PLUGIN_BASELINE:-openclaw@latest}"
2121update_timeout_seconds=" ${OPENCLAW_UPDATE_CORRUPT_PLUGIN_TIMEOUT_SECONDS:- 900} "
2222echo " Installing baseline OpenClaw package: $baseline "
2323if ! openclaw_e2e_maybe_timeout " ${OPENCLAW_E2E_NPM_INSTALL_TIMEOUT:- 600s} " npm install -g --prefix /tmp/npm-prefix --omit=optional " $baseline " > /tmp/openclaw-update-corrupt-baseline-install.log 2>&1 ; then
24- cat /tmp/openclaw-update-corrupt-baseline-install.log >&2 || true
24+ openclaw_e2e_print_log /tmp/openclaw-update-corrupt-baseline-install.log >&2
2525 exit 1
2626fi
2727
7272if [ " $update_status " -ne 0 ]; then
7373 if ! node scripts/e2e/lib/plugin-update/probe.mjs assert-legacy-post-update-plugin-failure /tmp/openclaw-update-corrupt-plugin.json; then
7474 echo " openclaw update failed or timed out after ${update_timeout_seconds} s with corrupt plugin present" >&2
75- cat /tmp/openclaw-update-corrupt-plugin.err >&2 || true
76- cat /tmp/openclaw-update-corrupt-plugin.json >&2 || true
75+ openclaw_e2e_print_log /tmp/openclaw-update-corrupt-plugin.err >&2
76+ openclaw_e2e_print_log /tmp/openclaw-update-corrupt-plugin.json >&2
7777 exit " $update_status "
7878 fi
7979 echo " Legacy updater reported post-update plugin failure after installing the new core; verifying updated entrypoint..."
@@ -92,9 +92,9 @@ if [ "$update_status" -ne 0 ]; then
9292 set -e
9393 if [ " $post_core_status " -ne 0 ]; then
9494 echo " updated OpenClaw entry failed or timed out after ${update_timeout_seconds} s during post-core plugin verification" >&2
95- cat /tmp/openclaw-update-corrupt-plugin-post-core.err >&2 || true
96- cat /tmp/openclaw-update-corrupt-plugin-post-core.stdout >&2 || true
97- cat /tmp/openclaw-update-corrupt-plugin-post-core.json >&2 || true
95+ openclaw_e2e_print_log /tmp/openclaw-update-corrupt-plugin-post-core.err >&2
96+ openclaw_e2e_print_log /tmp/openclaw-update-corrupt-plugin-post-core.stdout >&2
97+ openclaw_e2e_print_log /tmp/openclaw-update-corrupt-plugin-post-core.json >&2
9898 exit " $post_core_status "
9999 fi
100100 node scripts/e2e/lib/plugin-update/probe.mjs assert-corrupt-plugin-result /tmp/openclaw-update-corrupt-plugin-post-core.json demo-corrupt-plugin
103103
104104if ! node scripts/e2e/lib/plugin-update/probe.mjs assert-corrupt-update /tmp/openclaw-update-corrupt-plugin.json demo-corrupt-plugin; then
105105 echo " corrupt update JSON payload:" >&2
106- cat /tmp/openclaw-update-corrupt-plugin.json >&2 || true
106+ openclaw_e2e_print_log /tmp/openclaw-update-corrupt-plugin.json >&2
107107 echo " corrupt update stderr:" >&2
108- cat /tmp/openclaw-update-corrupt-plugin.err >&2 || true
108+ openclaw_e2e_print_log /tmp/openclaw-update-corrupt-plugin.err >&2
109109 exit 1
110110fi
0 commit comments