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

推荐订阅源

MyScale Blog
MyScale Blog
人人都是产品经理
人人都是产品经理
云风的 BLOG
云风的 BLOG
小众软件
小众软件
F
Fortinet All Blogs
爱范儿
爱范儿
WordPress大学
WordPress大学
N
Netflix TechBlog - Medium
Recent Announcements
Recent Announcements
Google DeepMind News
Google DeepMind News
C
Check Point Blog
博客园 - 聂微东
D
Docker
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
aimingoo的专栏
aimingoo的专栏
Vercel News
Vercel News
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
A
About on SuperTechFans
博客园 - 【当耐特】
Microsoft Azure Blog
Microsoft Azure Blog
B
Blog
宝玉的分享
宝玉的分享
Jina AI
Jina AI
H
Hackread – Cybersecurity News, Data Breaches, AI and More

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(codex): keep message registered for internal turns (#...
jalehman · 2026-06-18 · via Recent Commits to openclaw:main

@@ -74,7 +74,11 @@ import { createSandboxContext } from "./sandbox-exec-server.test-helpers.js";

7474

import { readCodexAppServerBinding, writeCodexAppServerBinding } from "./session-binding.js";

7575

import * as sharedClientModule from "./shared-client.js";

7676

import { createCodexTestModel } from "./test-support.js";

77-

import { buildTurnStartParams, startOrResumeThread } from "./thread-lifecycle.js";

77+

import {

78+

buildTurnStartParams,

79+

codexDynamicToolsFingerprint,

80+

startOrResumeThread,

81+

} from "./thread-lifecycle.js";

78827983

function flushDiagnosticEvents() {

8084

return waitForDiagnosticEventsDrained();

@@ -211,7 +215,7 @@ async function buildDynamicToolsForTest(

211215

options: Partial<

212216

Pick<

213217

Parameters<typeof testing.buildDynamicTools>[0],

214-

"forceHeartbeatTool" | "ignoreRuntimePlan"

218+

"forceHeartbeatTool" | "ignoreDisableMessageTool" | "ignoreRuntimePlan"

215219

>

216220

> = {},

217221

) {

@@ -309,7 +313,7 @@ function createCodexToolBridgeForTest(

309313

tools,

310314

registeredTools,

311315

signal,

312-

directToolNames: testing.shouldForceMessageTool(params) ? ["message"] : [],

316+

directToolNames: testing.resolveCodexDynamicToolDirectNames(params),

313317

});

314318

}

315319

@@ -1678,6 +1682,64 @@ describe("runCodexAppServerAttempt", () => {

16781682

expect(specNames(nextNormalBridge.specs)).toEqual(registeredToolNames);

16791683

});

168016841685+

it("keeps message in the registered schema when disabled for an internal turn", async () => {

1686+

testing.setOpenClawCodingToolsFactoryForTests((options) =>

1687+

options?.disableMessageTool ? [] : [createRuntimeDynamicTool("message")],

1688+

);

1689+

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

1690+

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

1691+

const params = createParams(sessionFile, workspaceDir);

1692+

params.disableTools = false;

1693+

params.disableMessageTool = true;

1694+

params.sourceReplyDeliveryMode = "message_tool_only";

1695+

params.runtimePlan = createCodexRuntimePlanFixture();

1696+1697+

const availableTools = await buildDynamicToolsForTest(params, workspaceDir);

1698+

const registeredTools = await buildDynamicToolsForTest(params, workspaceDir, {

1699+

ignoreDisableMessageTool: true,

1700+

ignoreRuntimePlan: true,

1701+

});

1702+

const bridge = createCodexToolBridgeForTest(params, availableTools, registeredTools);

1703+

const normalParams = createParams(sessionFile, workspaceDir);

1704+

normalParams.disableTools = false;

1705+

normalParams.sourceReplyDeliveryMode = "message_tool_only";

1706+

normalParams.runtimePlan = createCodexRuntimePlanFixture();

1707+

const normalTools = await buildDynamicToolsForTest(normalParams, workspaceDir);

1708+

const normalRegisteredTools = await buildDynamicToolsForTest(normalParams, workspaceDir, {

1709+

ignoreDisableMessageTool: true,

1710+

ignoreRuntimePlan: true,

1711+

});

1712+

const normalBridge = createCodexToolBridgeForTest(

1713+

normalParams,

1714+

normalTools,

1715+

normalRegisteredTools,

1716+

);

1717+1718+

expect(bridge.availableSpecs.map((tool) => tool.name)).not.toContain("message");

1719+

expect(bridge.specs.map((tool) => tool.name)).toContain("message");

1720+

expect(codexDynamicToolsFingerprint(bridge.specs)).toBe(

1721+

codexDynamicToolsFingerprint(normalBridge.specs),

1722+

);

1723+

await expect(

1724+

bridge.handleToolCall({

1725+

threadId: "thread-1",

1726+

turnId: "turn-1",

1727+

callId: "call-1",

1728+

namespace: null,

1729+

tool: "message",

1730+

arguments: {},

1731+

}),

1732+

).resolves.toMatchObject({

1733+

success: false,

1734+

contentItems: [

1735+

{

1736+

type: "inputText",

1737+

text: "OpenClaw tool is not available for this turn: message",

1738+

},

1739+

],

1740+

});

1741+

});

1742+16811743

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

16821744

testing.setOpenClawCodingToolsFactoryForTests((options) => [

16831745

createRuntimeDynamicTool("message"),