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

推荐订阅源

WordPress大学
WordPress大学
酷 壳 – CoolShell
酷 壳 – CoolShell
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
腾讯CDC
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
Jina AI
Jina AI
N
Netflix TechBlog - Medium
有赞技术团队
有赞技术团队
博客园 - 【当耐特】
MongoDB | Blog
MongoDB | Blog
P
Proofpoint News Feed
L
LangChain Blog
aimingoo的专栏
aimingoo的专栏
GbyAI
GbyAI
B
Blog
F
Fortinet All Blogs
T
Tailwind CSS Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
G
Google Developers Blog
A
About on SuperTechFans
C
Check Point Blog
Microsoft Security Blog
Microsoft Security Blog
MyScale Blog
MyScale Blog
B
Blog RSS Feed

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(cli): keep tools rpc namespace off plugin startup · o...
steipete · 2026-04-29 · via Recent Commits to openclaw:main

@@ -19,6 +19,7 @@ const buildProgramMock = vi.hoisted(() => vi.fn());

1919

const getProgramContextMock = vi.hoisted(() => vi.fn(() => null));

2020

const registerCoreCliByNameMock = vi.hoisted(() => vi.fn());

2121

const registerSubCliByNameMock = vi.hoisted(() => vi.fn());

22+

const registerPluginCliCommandsFromValidatedConfigMock = vi.hoisted(() => vi.fn(async () => ({})));

2223

const restoreTerminalStateMock = vi.hoisted(() => vi.fn());

2324

const hasEnvHttpProxyAgentConfiguredMock = vi.hoisted(() => vi.fn(() => false));

2425

const ensureGlobalUndiciEnvProxyDispatcherMock = vi.hoisted(() => vi.fn());

@@ -151,6 +152,10 @@ vi.mock("./program/register.subclis.js", () => ({

151152

registerSubCliByName: registerSubCliByNameMock,

152153

}));

153154155+

vi.mock("../plugins/cli.js", () => ({

156+

registerPluginCliCommandsFromValidatedConfig: registerPluginCliCommandsFromValidatedConfigMock,

157+

}));

158+154159

vi.mock("../terminal/restore.js", () => ({

155160

restoreTerminalState: restoreTerminalStateMock,

156161

}));

@@ -358,6 +363,7 @@ describe("runCli exit behavior", () => {

358363

["models list", ["node", "openclaw", "models", "list"]],

359364

["models status without live probe", ["node", "openclaw", "models", "status"]],

360365

["tasks list", ["node", "openclaw", "tasks", "list"]],

366+

["gateway tools namespace typo", ["node", "openclaw", "tools", "effective"]],

361367

["migrate", ["node", "openclaw", "migrate"]],

362368

])("skips managed proxy routing for %s", (_name, argv) => {

363369

expect(shouldStartProxyForCli(argv)).toBe(false);

@@ -379,6 +385,26 @@ describe("runCli exit behavior", () => {

379385

expect(startProxyMock).toHaveBeenCalledWith(undefined);

380386

});

381387388+

it("keeps gateway tool RPC names out of plugin command discovery", async () => {

389+

const parseAsync = vi.fn().mockResolvedValueOnce(undefined);

390+

buildProgramMock.mockReturnValueOnce({

391+

commands: [],

392+

parseAsync,

393+

});

394+395+

await runCli(["node", "openclaw", "tools", "effective"]);

396+397+

expect(startProxyMock).not.toHaveBeenCalled();

398+

expect(registerSubCliByNameMock).toHaveBeenCalledWith(expect.anything(), "tools", [

399+

"node",

400+

"openclaw",

401+

"tools",

402+

"effective",

403+

]);

404+

expect(registerPluginCliCommandsFromValidatedConfigMock).not.toHaveBeenCalled();

405+

expect(parseAsync).toHaveBeenCalledWith(["node", "openclaw", "tools", "effective"]);

406+

});

407+382408

it("fails protected commands when managed proxy activation fails", async () => {

383409

startProxyMock.mockRejectedValueOnce(new Error("proxy: enabled but no HTTP proxy URL"));

384410