惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

月光博客
月光博客
Microsoft Security Blog
Microsoft Security Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园 - 叶小钗
博客园 - 三生石上(FineUI控件)
爱范儿
爱范儿
T
Tailwind CSS Blog
F
Fortinet All Blogs
Blog — PlanetScale
Blog — PlanetScale
WordPress大学
WordPress大学
H
Help Net Security
Apple Machine Learning Research
Apple Machine Learning Research
Y
Y Combinator Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
GbyAI
GbyAI
Martin Fowler
Martin Fowler
有赞技术团队
有赞技术团队
腾讯CDC
V
V2EX
Jina AI
Jina AI
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
B
Blog
M
MIT News - Artificial intelligence
宝玉的分享
宝玉的分享

Recent Commits to openclaw:main

test: merge chat side-result checks · openclaw/openclaw@ddd2c2a test: merge cron history checks · openclaw/openclaw@f7eb746 test: merge responsive navigation shell checks · openclaw/openclaw@c2e4b47 docs(changelog): add codex oauth fixes · openclaw/openclaw@628e6cd test: merge navigation routing cases · openclaw/openclaw@5d8cecb Tests: mock channel registry bundled fallback · openclaw/openclaw@2b08233 Secrets: avoid broad web search discovery for single plugin config · openclaw/openclaw@a464f59 test: merge config view browser checks · openclaw/openclaw@20cf511 fix(status): align oauth health with runtime · openclaw/openclaw@eed7116 feat: add macOS screen snapshots for monitor preview (#67954) thanks … · openclaw/openclaw@f377db1 fix: report shared auth scopes in hello-ok (#67810) thanks @BunsDev · openclaw/openclaw@0b6c39b Auto-reply: avoid eager bundled route fallback · openclaw/openclaw@3ea1bf4 Tests: narrow session binding contract setup · openclaw/openclaw@54e4e16 fix(macOS): enable undo/redo in webchat composer text input (#34962) · openclaw/openclaw@00951dc Tests: speed up channel setup promotion · openclaw/openclaw@82b529a Docs: refresh agent instructions · openclaw/openclaw@5775fe2 fix(auth): serialize OAuth refresh across agents to fix #26322 (#67876) · openclaw/openclaw@8e79080 test: allow ollama public surface boundary test · openclaw/openclaw@7d4f1a6 Docs: add test performance guardrails · openclaw/openclaw@89706d3 Tests: restore context-engine usage proof · openclaw/openclaw@e4c4f95 Tests: slim context engine runtime coverage · openclaw/openclaw@74c198f ci: retry failed custom checkouts · openclaw/openclaw@0ee5baf test: trim duplicate provider auth onboarding cases · openclaw/openclaw@1ffc02e matrix: fix sessions_spawn --thread subagent session spawning (#67643) · openclaw/openclaw@1ce2596 test: reduce auth choice fixture churn · openclaw/openclaw@857b9cd test: mock health status config boundaries · openclaw/openclaw@9d5ab4a test: mock onboard config io boundary · openclaw/openclaw@299694d test: mock legacy state plugin boundaries · openclaw/openclaw@2713089 test: mock channel install boundaries · openclaw/openclaw@b945248 test: mock doctor preview channel boundaries · openclaw/openclaw@b1a3ad4
fix(e2e): bound bundled plugin lifecycle commands · openc...
vincentkoc · 2026-06-02 · via Recent Commits to openclaw:main

File tree

    • lib/bundled-plugin-install-uninstall

Original file line numberDiff line numberDiff line change

@@ -16,6 +16,7 @@ for env_name in \

1616

OPENCLAW_BUNDLED_PLUGIN_SWEEP_TOTAL \

1717

OPENCLAW_BUNDLED_PLUGIN_SWEEP_INDEX \

1818

OPENCLAW_BUNDLED_PLUGIN_SWEEP_IDS \

19+

OPENCLAW_BUNDLED_PLUGIN_SWEEP_COMMAND_TIMEOUT \

1920

OPENCLAW_BUNDLED_PLUGIN_RUNTIME_SMOKE \

2021

OPENCLAW_BUNDLED_PLUGIN_RUNTIME_PORT_BASE \

2122

OPENCLAW_BUNDLED_PLUGIN_RUNTIME_OUTPUT_CHARS \

Original file line numberDiff line numberDiff line change

@@ -19,11 +19,30 @@ openclaw_e2e_eval_test_state_from_b64 "${OPENCLAW_TEST_STATE_SCRIPT_B64:?missing

1919

probe="scripts/e2e/lib/bundled-plugin-install-uninstall/probe.mjs"

2020

runtime_smoke="scripts/e2e/lib/bundled-plugin-install-uninstall/runtime-smoke.mjs"

2121

node "$probe" select > /tmp/bundled-plugin-sweep-ids

22+

sweep_command_timeout="${OPENCLAW_BUNDLED_PLUGIN_SWEEP_COMMAND_TIMEOUT:-300s}"

2223
2324

now_ms() {

2425

node -e 'process.stdout.write(String(Date.now()))'

2526

}

2627
28+

run_logged_sweep_command() {

29+

local label="$1"

30+

local log_file="$2"

31+

shift 2

32+

if openclaw_e2e_maybe_timeout "$sweep_command_timeout" "$@" >"$log_file" 2>&1; then

33+

return 0

34+

else

35+

local status=$?

36+

cat "$log_file"

37+

if [ "$status" -eq 124 ]; then

38+

echo "Bundled plugin sweep command timed out after $sweep_command_timeout: $label" >&2

39+

else

40+

echo "Bundled plugin sweep command failed with status $status: $label" >&2

41+

fi

42+

return "$status"

43+

fi

44+

}

45+
2746

lifecycle_trace_enabled() {

2847

case "${OPENCLAW_PLUGIN_LIFECYCLE_TRACE:-}" in

2948

1 | true | TRUE | yes | YES)

@@ -53,10 +72,8 @@ for plugin_entry in "${plugin_entries[@]}"; do

5372

uninstall_log="/tmp/openclaw-uninstall-${plugin_index}.log"

5473

plugin_started_at="$(now_ms)"

5574

echo "Installing bundled plugin: $plugin_id ($plugin_dir)"

56-

node "$OPENCLAW_ENTRY" plugins install "$plugin_id" >"$install_log" 2>&1 || {

57-

cat "$install_log"

58-

exit 1

59-

}

75+

run_logged_sweep_command "install $plugin_id" "$install_log" \

76+

node "$OPENCLAW_ENTRY" plugins install "$plugin_id"

6077

if lifecycle_trace_enabled; then

6178

cat "$install_log"

6279

fi

@@ -74,10 +91,8 @@ for plugin_entry in "${plugin_entries[@]}"; do

7491

runtime_finished_at="$(now_ms)"

7592
7693

echo "Uninstalling bundled plugin: $plugin_id ($plugin_dir)"

77-

node "$OPENCLAW_ENTRY" plugins uninstall "$plugin_id" --force >"$uninstall_log" 2>&1 || {

78-

cat "$uninstall_log"

79-

exit 1

80-

}

94+

run_logged_sweep_command "uninstall $plugin_id" "$uninstall_log" \

95+

node "$OPENCLAW_ENTRY" plugins uninstall "$plugin_id" --force

8196

if lifecycle_trace_enabled; then

8297

cat "$uninstall_log"

8398

fi

Original file line numberDiff line numberDiff line change

@@ -201,6 +201,15 @@ describe("bundled plugin install/uninstall probe", () => {

201201

expect(sweep).not.toContain("readarray ");

202202

});

203203
204+

it("bounds bundled plugin package lifecycle commands", () => {

205+

const sweep = fs.readFileSync(sweepPath, "utf8");

206+
207+

expect(sweep).toContain("OPENCLAW_BUNDLED_PLUGIN_SWEEP_COMMAND_TIMEOUT:-300s");

208+

expect(sweep.match(/openclaw_e2e_maybe_timeout/g)).toHaveLength(1);

209+

expect(sweep).toContain('run_logged_sweep_command "install $plugin_id"');

210+

expect(sweep).toContain('run_logged_sweep_command "uninstall $plugin_id"');

211+

});

212+
204213

it("keeps runtime command output capture bounded", async () => {

205214

const runtimeSmoke = await import(pathToFileURL(runtimeSmokePath).href);

206215
Original file line numberDiff line numberDiff line change

@@ -1696,6 +1696,7 @@ test -f "$TMPDIR/docker-cmd-seen"

16961696
16971697

expect(runner).toContain("OPENCLAW_BUNDLED_PLUGIN_SWEEP_TOTAL");

16981698

expect(runner).toContain("OPENCLAW_BUNDLED_PLUGIN_SWEEP_INDEX");

1699+

expect(runner).toContain("OPENCLAW_BUNDLED_PLUGIN_SWEEP_COMMAND_TIMEOUT");

16991700

expect(runner).toContain("OPENCLAW_BUNDLED_PLUGIN_RUNTIME_READY_MS");

17001701

expect(runner).toContain("OPENCLAW_PLUGIN_LIFECYCLE_TRACE");

17011702

expect(runner).toContain("scripts/e2e/lib/bundled-plugin-install-uninstall/sweep.sh");