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

推荐订阅源

阮一峰的网络日志
阮一峰的网络日志
J
Java Code Geeks
Martin Fowler
Martin Fowler
宝玉的分享
宝玉的分享
V
Visual Studio Blog
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
M
MIT News - Artificial intelligence
U
Unit 42
博客园 - 三生石上(FineUI控件)
博客园 - 聂微东
The GitHub Blog
The GitHub Blog
I
InfoQ
WordPress大学
WordPress大学
H
Help Net Security
D
Docker
B
Blog
腾讯CDC
A
About on SuperTechFans
Recent Announcements
Recent Announcements
雷峰网
雷峰网
有赞技术团队
有赞技术团队
C
Check Point Blog
Y
Y Combinator Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC

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: honor embedded runtime tool allowlists (#77609) · op...
steipete · 2026-05-05 · via Recent Commits to openclaw:main

@@ -1,5 +1,6 @@

11

import { describe, expect, it } from "vitest";

22

import type { OpenClawConfig } from "../config/config.js";

3+

import { createOpenClawTools } from "./openclaw-tools.js";

34

import { isUpdatePlanToolEnabledForOpenClawTools } from "./openclaw-tools.registration.js";

45

import { createUpdatePlanTool } from "./tools/update-plan-tool.js";

56

@@ -31,6 +32,25 @@ describe("openclaw-tools update_plan gating", () => {

3132

expectUpdatePlanEnabled({ config: {} as OpenClawConfig }, false);

3233

});

333435+

it("does not expose update_plan from default tool construction", () => {

36+

const defaultTools = createOpenClawTools({

37+

config: {} as OpenClawConfig,

38+

disablePluginTools: true,

39+

modelProvider: "anthropic",

40+

modelId: "claude-sonnet-4-6",

41+

});

42+

const emptyAllowlistTools = createOpenClawTools({

43+

config: {} as OpenClawConfig,

44+

disablePluginTools: true,

45+

pluginToolAllowlist: [],

46+

modelProvider: "anthropic",

47+

modelId: "claude-sonnet-4-6",

48+

});

49+50+

expect(defaultTools.some((tool) => tool.name === "update_plan")).toBe(false);

51+

expect(emptyAllowlistTools.some((tool) => tool.name === "update_plan")).toBe(false);

52+

});

53+3454

it("registers update_plan when explicitly enabled", () => {

3555

const config = {

3656

tools: {

@@ -44,6 +64,54 @@ describe("openclaw-tools update_plan gating", () => {

4464

expect(createUpdatePlanTool().displaySummary).toBe("Track a short structured work plan.");

4565

});

466667+

it("registers update_plan when the runtime allowlist explicitly requests it", () => {

68+

const tools = createOpenClawTools({

69+

config: {} as OpenClawConfig,

70+

disablePluginTools: true,

71+

pluginToolAllowlist: ["update_plan"],

72+

modelProvider: "anthropic",

73+

modelId: "claude-sonnet-4-6",

74+

});

75+76+

expect(tools.some((tool) => tool.name === "update_plan")).toBe(true);

77+

});

78+79+

it("registers update_plan when a config allowlist group includes it", () => {

80+

const tools = createOpenClawTools({

81+

config: { tools: { allow: ["group:agents"] } } as OpenClawConfig,

82+

disablePluginTools: true,

83+

modelProvider: "anthropic",

84+

modelId: "claude-sonnet-4-6",

85+

});

86+87+

expect(tools.some((tool) => tool.name === "update_plan")).toBe(true);

88+

});

89+90+

it("registers update_plan when a runtime allowlist group includes it", () => {

91+

const tools = createOpenClawTools({

92+

config: {} as OpenClawConfig,

93+

disablePluginTools: true,

94+

pluginToolAllowlist: ["group:agents"],

95+

modelProvider: "anthropic",

96+

modelId: "claude-sonnet-4-6",

97+

});

98+99+

expect(tools.some((tool) => tool.name === "update_plan")).toBe(true);

100+

});

101+102+

it("respects deny policy while constructing update_plan for grouped allowlists", () => {

103+

const tools = createOpenClawTools({

104+

config: {} as OpenClawConfig,

105+

disablePluginTools: true,

106+

pluginToolAllowlist: ["group:agents"],

107+

pluginToolDenylist: ["update_plan"],

108+

modelProvider: "anthropic",

109+

modelId: "claude-sonnet-4-6",

110+

});

111+112+

expect(tools.some((tool) => tool.name === "update_plan")).toBe(false);

113+

});

114+47115

it("auto-enables update_plan for unconfigured GPT-5 openai runs", () => {

48116

// Criterion 1 of the GPT-5.4 parity gate ("no stalls after planning") is

49117

// universal, not opt-in. Unspecified executionContract on a supported