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

推荐订阅源

博客园 - 司徒正美
T
The Blog of Author Tim Ferriss
雷峰网
雷峰网
S
Secure Thoughts
GbyAI
GbyAI
Google DeepMind News
Google DeepMind News
P
Proofpoint News Feed
G
GRAHAM CLULEY
MongoDB | Blog
MongoDB | Blog
WordPress大学
WordPress大学
M
MIT News - Artificial intelligence
Martin Fowler
Martin Fowler
C
Cyber Attacks, Cyber Crime and Cyber Security
I
Intezer
A
About on SuperTechFans
Hugging Face - Blog
Hugging Face - Blog
T
Threatpost
S
Securelist
T
Tenable Blog
博客园_首页
P
Privacy International News Feed
Cisco Talos Blog
Cisco Talos Blog
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
月光博客
月光博客
C
CXSECURITY Database RSS Feed - CXSecurity.com
小众软件
小众软件
美团技术团队
Project Zero
Project Zero
The Cloudflare Blog
L
Lohrmann on Cybersecurity
The Register - Security
The Register - Security
B
Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
L
LINUX DO - 热门话题
C
CERT Recently Published Vulnerability Notes
C
Cybersecurity and Infrastructure Security Agency CISA
有赞技术团队
有赞技术团队
IT之家
IT之家
A
Arctic Wolf
Scott Helme
Scott Helme
Latest news
Latest news
T
Tailwind CSS Blog
Jina AI
Jina AI
Microsoft Azure Blog
Microsoft Azure Blog
Recent Announcements
Recent Announcements
Cyberwarzone
Cyberwarzone
宝玉的分享
宝玉的分享
The Hacker News
The Hacker News
S
Schneier on Security
Y
Y Combinator 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 test: trim doctor command hotspots · openclaw/openclaw@c66f16a test: isolate agent auth and spawn hotspots · openclaw/openclaw@9285935 test: stabilize MCP startup disposal race · openclaw/openclaw@dd9d2eb test: merge browser contract server suites · openclaw/openclaw@5817a76 test: narrow ollama provider discovery setup · openclaw/openclaw@a0d9598 build: declare qa-lab aimock runtime dependency · openclaw/openclaw@24431e5 test: speed up safe-bins exec harness · openclaw/openclaw@ee856ab test: preserve tool helpers in embedded runner mocks · openclaw/openclaw@acd86a0 refactor: move memory embeddings into provider plugins · openclaw/openclaw@77e6e4c test: reuse system-run temp fixtures · openclaw/openclaw@7e9ff0f test: trim hotspot wait overhead · openclaw/openclaw@12a59b0 Check: avoid duplicate boundary prep · openclaw/openclaw@baf11b8 test: reduce hotspot fixture overhead · openclaw/openclaw@3a59edd feat(ui): overhaul settings and slash command UX (#67819) thanks @Bun… · openclaw/openclaw@2cfb660 QA Matrix: exit cleanly on failure · openclaw/openclaw@42805d2 QA Matrix: isolate scenario coverage · openclaw/openclaw@7e659e1 Matrix: refresh crypto bootstrap state · openclaw/openclaw@94081d8 QA Lab: add provider registry · openclaw/openclaw@bb7e982 Matrix: add plugin changelog · openclaw/openclaw@4acab55 test: trim more hotspot overhead · openclaw/openclaw@f485311 test: trim remaining hotspot tests · openclaw/openclaw@6ba8626 test: narrow hotspot mocks · openclaw/openclaw@dbc8179 test: isolate gemini embedding request helpers · openclaw/openclaw@cd330f5 test: trim memory and mcp hotspots · openclaw/openclaw@fd48dfa test: slim provider registry mocks · openclaw/openclaw@2e08c77 test: harden Parallels update smoke · openclaw/openclaw@1a98090 feat: default Anthropic to Opus 4.7 · openclaw/openclaw@628b454 fix: harden node-host shell payload mutability checks · openclaw/openclaw@75c551e fix: land node-host approval binding for native binaries (#66731) (th… · openclaw/openclaw@29919bb CI: add daily schedule to CodeQL workflow (#67645) · openclaw/openclaw@69d25f5 fix(gateway): capture config hash after plugin auto-enable to prevent… · openclaw/openclaw@8c11210 fix: repair sanitized replay tool results before send (#67620) (thank… · openclaw/openclaw@c3c7a99 fix: restrict HTML timeout short-circuit to transient statuses · openclaw/openclaw@de129a6 fix: keep TUI watchdog bound to active run (#67401) (thanks @xantorres) · openclaw/openclaw@3525273 Gateway/skills: dedupe skills prefix-match + drop dead fallback on log · openclaw/openclaw@d7f489f Extensions/lmstudio: back off inference preload after consecutive fai… · openclaw/openclaw@b555214 TUI/streaming: add watchdog that resets the activity indicator after … · openclaw/openclaw@f44ab20 Agents/tool-loop: enable unknown-tool stream guard by default · openclaw/openclaw@36ed367 Gateway/skills: invalidate session skills snapshot on config write · openclaw/openclaw@b23d59a fix: classify HTML provider error pages correctly (#67642) (thanks @s… · openclaw/openclaw@e588e90 fix(skills): remove unused model-usage import (#67641) · openclaw/openclaw@55f05df docs(changelog): credit codex fix superseded PRs · openclaw/openclaw@e485f24 fix(openai-codex): normalize stale transport metadata in resolution a… · openclaw/openclaw@90801ba CI: pin Docker-related GitHub Actions (#67632) · openclaw/openclaw@f697b01 Android: modernize WebView and discovery API usage (#67627) · openclaw/openclaw@44a6e50 fix(deps): bump hono to 4.12.14 and @hono/node-server to 1.19.14 (GHS… · openclaw/openclaw@fbccc18 fix(deps): bump dompurify to 3.4.0 (#67614) · openclaw/openclaw@2c2dc00 CI: add explicit permissions to all workflow jobs (fixes code-scannin… · openclaw/openclaw@01b7516 fix: register bundled TTS providers and route overrides correctly (#6… · openclaw/openclaw@6ea3cdd fix: align host tilde paths with OS home (#62804) (thanks @stainlu) · openclaw/openclaw@ecfaf64 fix: flush creds queue before reconnect socket open (#67464) (thanks … · openclaw/openclaw@405c63f fix: strip standalone <function> tool call tags from visible text (#6… · openclaw/openclaw@78df859 fix(agents): preserve cli session metadata before transcript persist … · openclaw/openclaw@898fd04 docs(changelog): move cli transcript entry · openclaw/openclaw@c1817c6 fix(agents): normalize cli transcript api field · openclaw/openclaw@3a3fae0 docs(changelog): note cli transcript persistence · openclaw/openclaw@6c343f1 fix(agents): persist cli transcript turns · openclaw/openclaw@b8ef507 fix(msteams): harden security-sensitive flows (#65841) · openclaw/openclaw@c56b56e [Dashboard] Fix exec approval modal overflow for long command content… · openclaw/openclaw@053c5b0 Docs: remove QA changelog entry · openclaw/openclaw@7fd5771 QA: fix private runtime source loading (#67428) · openclaw/openclaw@d5933af docs(gateway): correct protocol.md schema path, hello-ok example, aut… · openclaw/openclaw@489404d CI: pin Node 22 runners to 22.18.0 · openclaw/openclaw@4ffa621 models.authStatus: normalize provider ids + tighten env-backed escape… · openclaw/openclaw@f2fdb9d Update CHANGELOG.md · openclaw/openclaw@7694a92 test(parallels): clean up npm update guard jobs · openclaw/openclaw@045ea7b Plugins: prefer scanDir override paths · openclaw/openclaw@b2974da fix(dreaming): default storage.mode to "separate" so phase blocks sto… · openclaw/openclaw@8c392f0 fix(memory-core): skip dreaming transcript ingestion via session stor… · openclaw/openclaw@a1b01f0 fix: dedupe replayed exec.finished node events (#67281) · openclaw/openclaw@5dcf526
test: clear plugin install broad matchers · openclaw/openclaw@fdb65c0
steipete · 2026-05-10 · via Recent Commits to openclaw:main

@@ -308,6 +308,35 @@ function expectFailedInstallResult<

308308

return params.result;

309309

}

310310311+

function expectWarningIncludes(warnings: readonly string[], fragment: string) {

312+

expect(warnings.some((warning) => warning.includes(fragment))).toBe(true);

313+

}

314+315+

function expectWarningExcludes(warnings: readonly string[], fragment: string) {

316+

expect(warnings.some((warning) => warning.includes(fragment))).toBe(false);

317+

}

318+319+

function requireRecord(value: unknown, label: string): Record<string, unknown> {

320+

if (!value || typeof value !== "object" || Array.isArray(value)) {

321+

throw new Error(`expected ${label} to be an object`);

322+

}

323+

return value as Record<string, unknown>;

324+

}

325+326+

function requireHookPayload(handler: ReturnType<typeof vi.fn>): Record<string, unknown> {

327+

const payload = handler.mock.calls[0]?.[0];

328+

return requireRecord(payload, "before_install hook payload");

329+

}

330+331+

function expectHookRequest(

332+

payload: Record<string, unknown>,

333+

expected: { kind: string; mode: string },

334+

) {

335+

const request = requireRecord(payload.request, "before_install hook request");

336+

expect(request.kind).toBe(expected.kind);

337+

expect(request.mode).toBe(expected.mode);

338+

}

339+311340

function mockSuccessfulCommandRun(run: ReturnType<typeof vi.mocked<typeof runCommandWithTimeout>>) {

312341

run.mockResolvedValue({

313342

code: 0,

@@ -635,12 +664,14 @@ describe("installPluginFromArchive", () => {

635664

});

636665637666

expect(result.ok).toBe(true);

638-

expect(vi.mocked(runCommandWithTimeout)).toHaveBeenCalledWith(

639-

expect.arrayContaining(["npm", "install"]),

640-

expect.objectContaining({

641-

cwd: expect.stringContaining(".openclaw-install-stage-"),

642-

}),

643-

);

667+

const commandRun = vi.mocked(runCommandWithTimeout).mock.calls[0];

668+

expect(commandRun?.[0]).toContain("npm");

669+

expect(commandRun?.[0]).toContain("install");

670+

const commandOptions = commandRun?.[1];

671+

if (!commandOptions || typeof commandOptions === "number") {

672+

throw new Error("expected command options object");

673+

}

674+

expect(commandOptions.cwd).toContain(".openclaw-install-stage-");

644675

});

645676646677

it("installs scoped archives, rejects duplicate installs, and allows updates", async () => {

@@ -1142,9 +1173,7 @@ describe("installPluginFromArchive", () => {

11421173

expect(result.error).toContain('Plugin "dangerous-plugin" installation blocked');

11431174

expect(result.error).toContain("dangerous code patterns detected");

11441175

}

1145-

expect(warnings).toEqual(

1146-

expect.arrayContaining([expect.stringContaining("dangerous code pattern")]),

1147-

);

1176+

expectWarningIncludes(warnings, "dangerous code pattern");

11481177

});

1149117811501179

it("allows package installs when dangerous scanner patterns are only in tests", async () => {

@@ -1168,9 +1197,7 @@ describe("installPluginFromArchive", () => {

11681197

const { result, warnings } = await installFromDirWithWarnings({ pluginDir, extensionsDir });

1169119811701199

expect(result.ok).toBe(true);

1171-

expect(warnings).not.toEqual(

1172-

expect.arrayContaining([expect.stringContaining("dangerous code pattern")]),

1173-

);

1200+

expectWarningExcludes(warnings, "dangerous code pattern");

11741201

});

1175120211761203

it("still scans declared package entrypoints when they live under test-looking paths", async () => {

@@ -2072,9 +2099,7 @@ describe("installPluginFromArchive", () => {

20722099

expect(result.code).toBe(PLUGIN_INSTALL_ERROR_CODE.SECURITY_SCAN_BLOCKED);

20732100

expect(result.error).toContain('Bundle "dangerous-bundle" installation blocked');

20742101

}

2075-

expect(warnings).toEqual(

2076-

expect.arrayContaining([expect.stringContaining("dangerous code pattern")]),

2077-

);

2102+

expectWarningIncludes(warnings, "dangerous code pattern");

20782103

});

2079210420802105

it("allows bundle installs when dangerous scanner patterns are only in tests", async () => {

@@ -2092,9 +2117,7 @@ describe("installPluginFromArchive", () => {

20922117

const { result, warnings } = await installFromDirWithWarnings({ pluginDir, extensionsDir });

2093211820942119

expect(result.ok).toBe(true);

2095-

expect(warnings).not.toEqual(

2096-

expect.arrayContaining([expect.stringContaining("dangerous code pattern")]),

2097-

);

2120+

expectWarningExcludes(warnings, "dangerous code pattern");

20982121

});

2099212221002123

it("blocks bundle installs when a vendored manifest declares a blocked dependency", async () => {

@@ -2372,27 +2395,22 @@ describe("installPluginFromArchive", () => {

2372239523732396

expect(result.ok).toBe(true);

23742397

expect(handler).toHaveBeenCalledTimes(1);

2375-

expect(handler.mock.calls[0]?.[0]).toMatchObject({

2376-

targetName: "hook-findings-plugin",

2377-

targetType: "plugin",

2378-

origin: "plugin-package",

2379-

sourcePath: pluginDir,

2380-

sourcePathKind: "directory",

2381-

request: {

2382-

kind: "plugin-dir",

2383-

mode: "install",

2384-

},

2385-

builtinScan: {

2386-

status: "ok",

2387-

findings: [],

2388-

},

2389-

plugin: {

2390-

contentType: "package",

2391-

pluginId: "hook-findings-plugin",

2392-

packageName: "hook-findings-plugin",

2393-

version: "1.0.0",

2394-

extensions: ["index.js"],

2395-

},

2398+

const payload = requireHookPayload(handler);

2399+

expect(payload.targetName).toBe("hook-findings-plugin");

2400+

expect(payload.targetType).toBe("plugin");

2401+

expect(payload.origin).toBe("plugin-package");

2402+

expect(payload.sourcePath).toBe(pluginDir);

2403+

expect(payload.sourcePathKind).toBe("directory");

2404+

expectHookRequest(payload, { kind: "plugin-dir", mode: "install" });

2405+

const builtinScan = requireRecord(payload.builtinScan, "builtin scan");

2406+

expect(builtinScan.status).toBe("ok");

2407+

expect(builtinScan.findings).toEqual([]);

2408+

expect(payload.plugin).toEqual({

2409+

contentType: "package",

2410+

pluginId: "hook-findings-plugin",

2411+

packageName: "hook-findings-plugin",

2412+

version: "1.0.0",

2413+

extensions: ["index.js"],

23962414

});

23972415

expect(handler.mock.calls[0]?.[1]).toEqual({

23982416

origin: "plugin-package",

@@ -2436,33 +2454,23 @@ describe("installPluginFromArchive", () => {

24362454

expect(result.code).toBeUndefined();

24372455

}

24382456

expect(handler).toHaveBeenCalledTimes(1);

2439-

expect(handler.mock.calls[0]?.[0]).toMatchObject({

2440-

targetName: "dangerous-blocked-plugin",

2441-

targetType: "plugin",

2442-

origin: "plugin-package",

2443-

request: {

2444-

kind: "plugin-dir",

2445-

mode: "install",

2446-

},

2447-

builtinScan: {

2448-

status: "ok",

2449-

findings: [

2450-

expect.objectContaining({

2451-

severity: "critical",

2452-

}),

2453-

],

2454-

},

2455-

plugin: {

2456-

contentType: "package",

2457-

pluginId: "dangerous-blocked-plugin",

2458-

packageName: "dangerous-blocked-plugin",

2459-

version: "1.0.0",

2460-

extensions: ["index.js"],

2461-

},

2457+

const payload = requireHookPayload(handler);

2458+

expect(payload.targetName).toBe("dangerous-blocked-plugin");

2459+

expect(payload.targetType).toBe("plugin");

2460+

expect(payload.origin).toBe("plugin-package");

2461+

expectHookRequest(payload, { kind: "plugin-dir", mode: "install" });

2462+

const builtinScan = requireRecord(payload.builtinScan, "builtin scan");

2463+

expect(builtinScan.status).toBe("ok");

2464+

const findings = builtinScan.findings as Array<{ severity?: string }>;

2465+

expect(findings.some((finding) => finding.severity === "critical")).toBe(true);

2466+

expect(payload.plugin).toEqual({

2467+

contentType: "package",

2468+

pluginId: "dangerous-blocked-plugin",

2469+

packageName: "dangerous-blocked-plugin",

2470+

version: "1.0.0",

2471+

extensions: ["index.js"],

24622472

});

2463-

expect(warnings).toEqual(

2464-

expect.arrayContaining([expect.stringContaining("dangerous code pattern")]),

2465-

);

2473+

expectWarningIncludes(warnings, "dangerous code pattern");

24662474

expect(

24672475

warnings.some((w) => w.includes("blocked by plugin hook: Blocked by enterprise policy")),

24682476

).toBe(true);

@@ -2538,12 +2546,7 @@ describe("installPluginFromArchive", () => {

2538254625392547

expect(result.ok).toBe(true);

25402548

expect(handler).toHaveBeenCalledTimes(1);

2541-

expect(handler.mock.calls[0]?.[0]).toMatchObject({

2542-

request: {

2543-

kind: "plugin-dir",

2544-

mode: "install",

2545-

},

2546-

});

2549+

expectHookRequest(requireHookPayload(handler), { kind: "plugin-dir", mode: "install" });

25472550

});

2548255125492552

it("reports update mode to before_install when replacing an existing target", async () => {

@@ -2576,12 +2579,7 @@ describe("installPluginFromArchive", () => {

2576257925772580

expect(result.ok).toBe(true);

25782581

expect(handler).toHaveBeenCalledTimes(1);

2579-

expect(handler.mock.calls[0]?.[0]).toMatchObject({

2580-

request: {

2581-

kind: "plugin-dir",

2582-

mode: "update",

2583-

},

2584-

});

2582+

expectHookRequest(requireHookPayload(handler), { kind: "plugin-dir", mode: "update" });

25852583

});

2586258425872585

it("scans extension entry files in hidden directories", async () => {

@@ -2604,12 +2602,8 @@ describe("installPluginFromArchive", () => {

26042602

const { result, warnings } = await installFromDirWithWarnings({ pluginDir, extensionsDir });

2605260326062604

expect(result.ok).toBe(false);

2607-

expect(warnings).toEqual(

2608-

expect.arrayContaining([expect.stringContaining("hidden/node_modules path")]),

2609-

);

2610-

expect(warnings).toEqual(

2611-

expect.arrayContaining([expect.stringContaining("dangerous code pattern")]),

2612-

);

2605+

expectWarningIncludes(warnings, "hidden/node_modules path");

2606+

expectWarningIncludes(warnings, "dangerous code pattern");

26132607

});

2614260826152609

it("blocks install when scanner throws", async () => {

@@ -2823,9 +2817,7 @@ describe("installPluginFromDir", () => {

28232817

});

2824281828252819

expectInstalledWithPluginId(res, extensionsDir, "matrix");

2826-

expect(infoMessages).not.toEqual(

2827-

expect.arrayContaining([expect.stringContaining("differs from npm package name")]),

2828-

);

2820+

expectWarningExcludes(infoMessages, "differs from npm package name");

28292821

});

2830282228312823

it.each([

@@ -3078,8 +3070,6 @@ describe("linkOpenClawPeerDependencies (via installPluginFromDir)", () => {

30783070

const { result, warnings } = await installFromDirWithWarnings({ pluginDir, extensionsDir });

3079307130803072

expect(result.ok).toBe(true);

3081-

expect(warnings).toEqual(

3082-

expect.arrayContaining([expect.stringContaining("Could not locate openclaw package root")]),

3083-

);

3073+

expectWarningIncludes(warnings, "Could not locate openclaw package root");

30843074

});

30853075

});