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

推荐订阅源

Vercel News
Vercel News
博客园 - 司徒正美
C
Check Point Blog
G
Google Developers Blog
The GitHub Blog
The GitHub Blog
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
有赞技术团队
有赞技术团队
P
Proofpoint News Feed
IT之家
IT之家
B
Blog
博客园_首页
量子位
MongoDB | Blog
MongoDB | Blog
博客园 - Franky
J
Java Code Geeks
H
Help Net Security
A
About on SuperTechFans
Apple Machine Learning Research
Apple Machine Learning Research
Jina AI
Jina AI
D
DataBreaches.Net
Y
Y Combinator Blog
大猫的无限游戏
大猫的无限游戏
云风的 BLOG
云风的 BLOG
Google DeepMind News
Google DeepMind News

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
ci: harden beta release validation flakes · openclaw/open...
steipete · 2026-05-24 · via Recent Commits to openclaw:main

@@ -555,23 +555,12 @@ async function buildDynamicToolsForTest(

555555

});

556556

}

557557558-

async function createCodexToolBridgeForTest(

558+

function createCodexToolBridgeForTest(

559559

params: EmbeddedRunAttemptParams,

560-

workspaceDir: string,

561-

options: Partial<

562-

Pick<

563-

Parameters<typeof testing.buildDynamicTools>[0],

564-

"forceHeartbeatTool" | "ignoreRuntimePlan"

565-

>

566-

> = {},

560+

tools: RuntimeDynamicToolForTest[],

561+

registeredTools: RuntimeDynamicToolForTest[] = tools,

567562

) {

568563

const signal = new AbortController().signal;

569-

const tools = await buildDynamicToolsForTest(params, workspaceDir, options);

570-

const registeredTools = await buildDynamicToolsForTest(params, workspaceDir, {

571-

...options,

572-

forceHeartbeatTool: true,

573-

ignoreRuntimePlan: true,

574-

});

575564

return createCodexDynamicToolBridge({

576565

tools,

577566

registeredTools,

@@ -2383,18 +2372,8 @@ describe("runCodexAppServerAttempt", () => {

23832372

? [createRuntimeDynamicTool("heartbeat_respond")]

23842373

: []),

23852374

]);

2386-

const request = vi.fn(async (method: string, _params?: unknown) => {

2387-

if (method === "thread/start") {

2388-

return threadStartResult("thread-1");

2389-

}

2390-

if (method === "thread/resume") {

2391-

return threadStartResult("thread-1");

2392-

}

2393-

throw new Error(`unexpected method: ${method}`);

2394-

});

23952375

const sessionFile = path.join(tempDir, "session.jsonl");

23962376

const workspaceDir = path.join(tempDir, "workspace");

2397-

const appServer = createThreadLifecycleAppServerOptions();

23982377

const createRunParams = (trigger?: EmbeddedRunAttemptParams["trigger"]) => {

23992378

const params = createParams(sessionFile, workspaceDir);

24002379

params.disableTools = false;

@@ -2407,47 +2386,43 @@ describe("runCodexAppServerAttempt", () => {

24072386

}

24082387

return params;

24092388

};

2410-

const startOrResume = async (params: EmbeddedRunAttemptParams) => {

2411-

const toolBridge = await createCodexToolBridgeForTest(params, workspaceDir);

2412-

return startOrResumeThread({

2413-

client: { request } as never,

2414-

params,

2415-

cwd: workspaceDir,

2416-

dynamicTools: toolBridge.specs,

2417-

appServer,

2418-

developerInstructions: testing.buildDeveloperInstructions(params, {

2419-

dynamicTools: toolBridge.availableSpecs,

2420-

}),

2421-

nativeCodeModeEnabled: true,

2422-

userMcpServersEnabled: false,

2423-

});

2424-

};

242523892426-

await startOrResume(createRunParams());

2427-2428-

const startRequest = request.mock.calls.find(([method]) => method === "thread/start");

2429-

const startParams = startRequest?.[1] as

2430-

| { dynamicTools?: Array<{ name?: string }>; developerInstructions?: string }

2431-

| undefined;

2432-

const registeredToolNames = startParams?.dynamicTools?.map((tool) => tool.name) ?? [];

2390+

const registeredTools = [

2391+

createRuntimeDynamicTool("message"),

2392+

createRuntimeDynamicTool("heartbeat_respond"),

2393+

];

2394+

const normalBridge = createCodexToolBridgeForTest(

2395+

createRunParams(),

2396+

[createRuntimeDynamicTool("message")],

2397+

registeredTools,

2398+

);

2399+

const normalInstructions = testing.buildDeveloperInstructions(createRunParams(), {

2400+

dynamicTools: normalBridge.availableSpecs,

2401+

});

2402+

const registeredToolNames = normalBridge.specs.map((tool) => tool.name);

2433240324342404

expect(registeredToolNames).toContain("message");

24352405

expect(registeredToolNames).toContain("heartbeat_respond");

2436-

expect(startParams?.developerInstructions).toContain(

2406+

expect(normalInstructions).toContain(

24372407

"Deferred searchable OpenClaw dynamic tools available: message.",

24382408

);

2439-

expect(startParams?.developerInstructions).not.toContain(

2409+

expect(normalInstructions).not.toContain(

24402410

"Deferred searchable OpenClaw dynamic tools available: heartbeat_respond",

24412411

);

244224122443-

await startOrResume(createRunParams("heartbeat"));

2444-

await startOrResume(createRunParams());

2413+

const heartbeatBridge = createCodexToolBridgeForTest(

2414+

createRunParams("heartbeat"),

2415+

[createRuntimeDynamicTool("message"), createRuntimeDynamicTool("heartbeat_respond")],

2416+

registeredTools,

2417+

);

2418+

const nextNormalBridge = createCodexToolBridgeForTest(

2419+

createRunParams(),

2420+

[createRuntimeDynamicTool("message")],

2421+

registeredTools,

2422+

);

244524232446-

expect(request.mock.calls.map(([method]) => method)).toEqual([

2447-

"thread/start",

2448-

"thread/resume",

2449-

"thread/resume",

2450-

]);

2424+

expect(heartbeatBridge.specs.map((tool) => tool.name)).toEqual(registeredToolNames);

2425+

expect(nextNormalBridge.specs.map((tool) => tool.name)).toEqual(registeredToolNames);

24512426

});

2452242724532428

it("keeps the persistent dynamic schema stable across heartbeat-only turns", async () => {

@@ -2458,18 +2433,8 @@ describe("runCodexAppServerAttempt", () => {

24582433

? [createRuntimeDynamicTool("heartbeat_respond")]

24592434

: []),

24602435

]);

2461-

const request = vi.fn(async (method: string, _params?: unknown) => {

2462-

if (method === "thread/start") {

2463-

return threadStartResult("thread-1");

2464-

}

2465-

if (method === "thread/resume") {

2466-

return threadStartResult("thread-1");

2467-

}

2468-

throw new Error(`unexpected method: ${method}`);

2469-

});

24702436

const sessionFile = path.join(tempDir, "session.jsonl");

24712437

const workspaceDir = path.join(tempDir, "workspace");

2472-

const appServer = createThreadLifecycleAppServerOptions();

24732438

const createRunParams = (trigger?: EmbeddedRunAttemptParams["trigger"]) => {

24742439

const params = createParams(sessionFile, workspaceDir);

24752440

params.disableTools = false;

@@ -2489,31 +2454,34 @@ describe("runCodexAppServerAttempt", () => {

24892454

}

24902455

return params;

24912456

};

2492-

const startOrResume = async (params: EmbeddedRunAttemptParams) => {

2493-

const toolBridge = await createCodexToolBridgeForTest(params, workspaceDir);

2494-

return startOrResumeThread({

2495-

client: { request } as never,

2496-

params,

2497-

cwd: workspaceDir,

2498-

dynamicTools: toolBridge.specs,

2499-

appServer,

2500-

developerInstructions: testing.buildDeveloperInstructions(params, {

2501-

dynamicTools: toolBridge.availableSpecs,

2502-

}),

2503-

nativeCodeModeEnabled: true,

2504-

userMcpServersEnabled: false,

2505-

});

2506-

};

2507-2508-

await startOrResume(createRunParams());

2509-

await startOrResume(createRunParams("heartbeat"));

2510-

await startOrResume(createRunParams());

2457+

const registeredTools = [

2458+

createRuntimeDynamicTool("message"),

2459+

createRuntimeDynamicTool("web_search"),

2460+

createRuntimeDynamicTool("heartbeat_respond"),

2461+

];

2462+

const normalBridge = createCodexToolBridgeForTest(

2463+

createRunParams(),

2464+

registeredTools,

2465+

registeredTools,

2466+

);

2467+

const heartbeatBridge = createCodexToolBridgeForTest(

2468+

createRunParams("heartbeat"),

2469+

[createRuntimeDynamicTool("heartbeat_respond")],

2470+

registeredTools,

2471+

);

2472+

const nextNormalBridge = createCodexToolBridgeForTest(

2473+

createRunParams(),

2474+

registeredTools,

2475+

registeredTools,

2476+

);

251124772512-

expect(

2513-

request.mock.calls

2514-

.map(([method]) => method)

2515-

.filter((method) => method === "thread/start" || method === "thread/resume"),

2516-

).toEqual(["thread/start", "thread/resume", "thread/resume"]);

2478+

expect(heartbeatBridge.availableSpecs.map((tool) => tool.name)).toEqual(["heartbeat_respond"]);

2479+

expect(heartbeatBridge.specs.map((tool) => tool.name)).toEqual(

2480+

normalBridge.specs.map((tool) => tool.name),

2481+

);

2482+

expect(nextNormalBridge.specs.map((tool) => tool.name)).toEqual(

2483+

normalBridge.specs.map((tool) => tool.name),

2484+

);

25172485

});

2518248625192487

it("disables Codex native tool surfaces when runtime toolsAllow is empty", async () => {