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

推荐订阅源

月光博客
月光博客
J
Java Code Geeks
F
Fortinet All Blogs
Blog — PlanetScale
Blog — PlanetScale
P
Proofpoint News Feed
U
Unit 42
B
Blog
宝玉的分享
宝玉的分享
腾讯CDC
Microsoft Azure Blog
Microsoft Azure Blog
酷 壳 – CoolShell
酷 壳 – CoolShell
Last Week in AI
Last Week in AI
博客园 - Franky
博客园 - 三生石上(FineUI控件)
人人都是产品经理
人人都是产品经理
Martin Fowler
Martin Fowler
博客园_首页
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
云风的 BLOG
云风的 BLOG
L
LangChain Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
Y
Y Combinator Blog
The GitHub Blog
The GitHub Blog
博客园 - 叶小钗

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
refactor: share docker e2e harness runner · openclaw/open...
steipete · 2026-04-29 · via Recent Commits to openclaw:main

@@ -8,76 +8,20 @@ openclaw_e2e_install_package /tmp/openclaw-install.log "mounted OpenClaw package

8899

package_root="$(openclaw_e2e_package_root /tmp/npm-prefix)"

1010

entry="$(openclaw_e2e_package_entrypoint "$package_root")"

11+

probe="scripts/e2e/lib/plugin-update/probe.mjs"

1112

package_version="$(node -p "require('$package_root/package.json').version")"

12-

OPENCLAW_PACKAGE_ACCEPTANCE_LEGACY_COMPAT="$(

13-

PACKAGE_VERSION="$package_version" node -e 'const version = process.env.PACKAGE_VERSION || ""; const match = new RegExp("^(\\d{4})\\.(\\d{1,2})\\.(\\d{1,2})(?:[-+].*)?").exec(version); if (!match) { console.log("0"); process.exit(0); } const value = [Number(match[1]), Number(match[2]), Number(match[3])]; const max = [2026, 4, 25]; for (let i = 0; i < value.length; i += 1) { if (value[i] < max[i]) { console.log("1"); process.exit(0); } if (value[i] > max[i]) { console.log("0"); process.exit(0); } } console.log("1");'

14-

)"

13+

OPENCLAW_PACKAGE_ACCEPTANCE_LEGACY_COMPAT="$(node "$probe" legacy-compat "$package_version")"

1514

export OPENCLAW_PACKAGE_ACCEPTANCE_LEGACY_COMPAT

1615

export NPM_CONFIG_REGISTRY=http://127.0.0.1:4873

1716

export PATH="/tmp/npm-prefix/bin:$PATH"

181719-

mkdir -p "$HOME/.openclaw/extensions/lossless-claw"

20-

cat > "$HOME/.openclaw/extensions/lossless-claw/package.json" <<'JSON'

21-

{

22-

"name": "@example/lossless-claw",

23-

"version": "0.9.0"

24-

}

25-

JSON

26-

cat > "$OPENCLAW_CONFIG_PATH" <<'JSON'

27-

{

28-

"plugins": {}

29-

}

30-

JSON

31-

mkdir -p "$HOME/.openclaw/plugins"

32-

cat > "$HOME/.openclaw/plugins/installs.json" <<'JSON'

33-

{

34-

"version": 1,

35-

"warning": "DO NOT EDIT. This file is generated by OpenClaw plugin registry commands.",

36-

"hostContractVersion": "docker-e2e",

37-

"compatRegistryVersion": "docker-e2e",

38-

"migrationVersion": 1,

39-

"policyHash": "docker-e2e",

40-

"generatedAtMs": 1777118400000,

41-

"installRecords": {

42-

"lossless-claw": {

43-

"source": "npm",

44-

"spec": "@example/lossless-claw@0.9.0",

45-

"installPath": "~/.openclaw/extensions/lossless-claw",

46-

"resolvedName": "@example/lossless-claw",

47-

"resolvedVersion": "0.9.0",

48-

"resolvedSpec": "@example/lossless-claw@0.9.0",

49-

"integrity": "sha512-same",

50-

"shasum": "same"

51-

}

52-

},

53-

"plugins": [],

54-

"diagnostics": []

55-

}

56-

JSON

18+

node "$probe" seed

57195820

node scripts/e2e/lib/plugin-update/registry-server.mjs >/tmp/openclaw-e2e-registry.log 2>&1 &

5921

registry_pid=$!

6022

trap 'kill "$registry_pid" >/dev/null 2>&1 || true' EXIT

612362-

registry_ready=0

63-

for _ in $(seq 1 50); do

64-

if node --input-type=module -e '

65-

import http from "node:http";

66-

const req = http.get("http://127.0.0.1:4873/@example%2flossless-claw", (res) => {

67-

process.exit(res.statusCode === 200 ? 0 : 1);

68-

});

69-

req.on("error", () => process.exit(1));

70-

req.setTimeout(200, () => {

71-

req.destroy();

72-

process.exit(1);

73-

});

74-

'; then

75-

registry_ready=1

76-

break

77-

fi

78-

sleep 0.1

79-

done

80-

if [ "$registry_ready" -ne 1 ]; then

24+

if ! node "$probe" wait-registry; then

8125

echo "Local npm metadata registry failed to start"

8226

cat /tmp/openclaw-e2e-registry.log || true

8327

exit 1

@@ -89,37 +33,7 @@ if [ "$OPENCLAW_PACKAGE_ACCEPTANCE_LEGACY_COMPAT" != "1" ]; then

8933

fi

9034

plugin_update_timeout_seconds="${OPENCLAW_PLUGIN_UPDATE_TIMEOUT_SECONDS:-180}"

913592-

node --input-type=module > /tmp/plugin-update-before.json <<'NODE'

93-

import fs from "node:fs";

94-

import os from "node:os";

95-

import path from "node:path";

96-97-

const readJson = (file) => {

98-

try {

99-

return JSON.parse(fs.readFileSync(file, "utf8"));

100-

} catch {

101-

return {};

102-

}

103-

};

104-

const home = os.homedir();

105-

const config = readJson(path.join(home, ".openclaw", "openclaw.json"));

106-

const index = readJson(path.join(home, ".openclaw", "plugins", "installs.json"));

107-

const records = index.installRecords ?? index.records ?? config.plugins?.installs ?? {};

108-

const record = records["lossless-claw"] ?? records["@example/lossless-claw"];

109-

if (!record) {

110-

throw new Error("missing seeded plugin install record");

111-

}

112-

const snapshot = {

113-

source: record.source,

114-

spec: record.spec,

115-

resolvedName: record.resolvedName,

116-

resolvedVersion: record.resolvedVersion,

117-

resolvedSpec: record.resolvedSpec,

118-

integrity: record.integrity,

119-

shasum: record.shasum,

120-

};

121-

process.stdout.write(JSON.stringify(snapshot, null, 2));

122-

NODE

36+

node "$probe" snapshot > /tmp/plugin-update-before.json

1233712438

set +e

12539

timeout "${plugin_update_timeout_seconds}s" node "$entry" plugins update @example/lossless-claw > /tmp/plugin-update-output.log 2>&1

@@ -143,48 +57,6 @@ if [ -n "$before_config_hash" ]; then

14357

fi

14458

fi

14559146-

node --input-type=module <<'NODE'

147-

import fs from "node:fs";

148-

import os from "node:os";

149-

import path from "node:path";

150-151-

const readJson = (file) => {

152-

try {

153-

return JSON.parse(fs.readFileSync(file, "utf8"));

154-

} catch {

155-

return {};

156-

}

157-

};

158-

const home = os.homedir();

159-

const before = readJson("/tmp/plugin-update-before.json");

160-

const config = readJson(path.join(home, ".openclaw", "openclaw.json"));

161-

const index = readJson(path.join(home, ".openclaw", "plugins", "installs.json"));

162-

const records = index.installRecords ?? index.records ?? config.plugins?.installs ?? {};

163-

const record = records["lossless-claw"] ?? records["@example/lossless-claw"];

164-

if (!record) {

165-

throw new Error("missing plugin install record after update");

166-

}

167-

const after = {

168-

source: record.source,

169-

spec: record.spec,

170-

resolvedName: record.resolvedName,

171-

resolvedVersion: record.resolvedVersion,

172-

resolvedSpec: record.resolvedSpec,

173-

integrity: record.integrity,

174-

shasum: record.shasum,

175-

};

176-

if (JSON.stringify(before) !== JSON.stringify(after)) {

177-

throw new Error(`plugin install record changed unexpectedly: ${JSON.stringify({ before, after })}`);

178-

}

179-

NODE

180-

if grep -q "Downloading @example/lossless-claw" /tmp/plugin-update-output.log; then

181-

echo "Unexpected npm download/reinstall path"

182-

cat /tmp/plugin-update-output.log

183-

exit 1

184-

fi

185-

if ! grep -q "lossless-claw is up to date (0.9.0)." /tmp/plugin-update-output.log; then

186-

echo "Expected up-to-date output missing"

187-

cat /tmp/plugin-update-output.log

188-

exit 1

189-

fi

60+

node "$probe" assert-snapshot /tmp/plugin-update-before.json

61+

node "$probe" assert-output /tmp/plugin-update-output.log

19062

cat /tmp/plugin-update-output.log