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

推荐订阅源

人人都是产品经理
人人都是产品经理
量子位
月光博客
月光博客
罗磊的独立博客
宝玉的分享
宝玉的分享
博客园_首页
酷 壳 – CoolShell
酷 壳 – CoolShell
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
WordPress大学
WordPress大学
博客园 - 叶小钗
博客园 - 聂微东
阮一峰的网络日志
阮一峰的网络日志
V
V2EX
雷峰网
雷峰网
博客园 - 三生石上(FineUI控件)
Jina AI
Jina AI
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
博客园 - Franky
美团技术团队
爱范儿
爱范儿
V
Visual Studio Blog
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
H
Hackread – Cybersecurity News, Data Breaches, AI and More
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
fix: restore verbose command and ACP cleanup controls · o...
steipete · 2026-04-29 · via Recent Commits to openclaw:main
Original file line numberDiff line numberDiff line change

@@ -18,6 +18,7 @@ Docs: https://docs.openclaw.ai

1818
1919

### Fixes

2020
21+

- ACP/commands: accept forwarded ACP timeout config controls in the OpenClaw bridge, treat unsupported discard-close controls as recoverable cleanup, and restore native `/verbose full` plus no-arg status behavior, so Discord command menus and nested ACP turns no longer fail on supported session controls. Thanks @vincentkoc.

2122

- Channels/Discord: fail startup closed when Discord cannot resolve the bot's own identity and keep mention gating active when only configured mention patterns can detect mentions, so the provider no longer continues with a missing bot id. Fixes #42219; carries forward #46856 and #49218. Thanks @education-01 and @BenediktSchackenberg.

2223

- Channels/Discord: split long CJK replies at punctuation and code-point-safe fallback boundaries so Discord chunking stays readable without corrupting astral characters. Fixes #38597; repairs #71384. Thanks @p3nchan.

2324

- Browser/gateway: ignore Playwright dialog-close races from `Page.handleJavaScriptDialog` so browser automation no longer crashes the Gateway when a dialog disappears before Playwright accepts it. (#40067) Thanks @randyjtw.

Original file line numberDiff line numberDiff line change

@@ -1297,6 +1297,8 @@ export class AcpSessionManager {

12971297

(acpError.code === "ACP_BACKEND_MISSING" ||

12981298

acpError.code === "ACP_BACKEND_UNAVAILABLE" ||

12991299

(input.discardPersistentState && acpError.code === "ACP_SESSION_INIT_FAILED") ||

1300+

(input.discardPersistentState &&

1301+

acpError.code === "ACP_BACKEND_UNSUPPORTED_CONTROL") ||

13001302

this.isRecoverableAcpxExitError(acpError.message))

13011303

) {

13021304

if (input.discardPersistentState) {

Original file line numberDiff line numberDiff line change

@@ -1555,6 +1555,44 @@ describe("AcpSessionManager", () => {

15551555

});

15561556

});

15571557
1558+

it("treats unsupported close controls as recoverable during discard cleanup", async () => {

1559+

const runtimeState = createRuntime();

1560+

runtimeState.close.mockRejectedValueOnce(

1561+

new AcpRuntimeError(

1562+

"ACP_BACKEND_UNSUPPORTED_CONTROL",

1563+

'ACP backend "acpx" does not support session/close.',

1564+

),

1565+

);

1566+

hoisted.requireAcpRuntimeBackendMock.mockReturnValue({

1567+

id: "acpx",

1568+

runtime: runtimeState.runtime,

1569+

});

1570+

hoisted.readAcpSessionEntryMock.mockReturnValue({

1571+

sessionKey: "agent:openclaw:acp:session-1",

1572+

storeSessionKey: "agent:openclaw:acp:session-1",

1573+

acp: readySessionMeta({

1574+

agent: "openclaw",

1575+

}),

1576+

});

1577+
1578+

const manager = new AcpSessionManager();

1579+

const closeResult = await manager.closeSession({

1580+

cfg: baseCfg,

1581+

sessionKey: "agent:openclaw:acp:session-1",

1582+

reason: "terminal-task-cleanup",

1583+

allowBackendUnavailable: true,

1584+

discardPersistentState: true,

1585+

clearMeta: true,

1586+

});

1587+
1588+

expect(closeResult.runtimeClosed).toBe(false);

1589+

expect(closeResult.runtimeNotice).toContain("does not support session/close");

1590+

expect(closeResult.metaCleared).toBe(true);

1591+

expect(runtimeState.prepareFreshSession).toHaveBeenCalledWith({

1592+

sessionKey: "agent:openclaw:acp:session-1",

1593+

});

1594+

});

1595+
15581596

it("clears persisted resume identity when close discards persistent state", async () => {

15591597

const runtimeState = createRuntime();

15601598

const sessionKey = "agent:claude:acp:binding:discord:default:9373ab192b2317f4";

Original file line numberDiff line numberDiff line change

@@ -742,6 +742,56 @@ describe("acp setSessionConfigOption bridge behavior", () => {

742742

sessionStore.clearAllSessionsForTest();

743743

});

744744
745+

it("accepts forwarded timeout config options without failing OpenClaw ACP bridge turns", async () => {

746+

const sessionStore = createInMemorySessionStore();

747+

const connection = createAcpConnection();

748+

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

749+

if (method === "sessions.list") {

750+

return {

751+

ts: Date.now(),

752+

path: "/tmp/sessions.json",

753+

count: 1,

754+

defaults: {

755+

modelProvider: null,

756+

model: null,

757+

contextTokens: null,

758+

},

759+

sessions: [

760+

{

761+

key: "timeout-session",

762+

kind: "direct",

763+

updatedAt: Date.now(),

764+

thinkingLevel: "minimal",

765+

modelProvider: "openai",

766+

model: "gpt-5.4",

767+

},

768+

],

769+

};

770+

}

771+

expect(method).not.toBe("sessions.patch");

772+

return { ok: true };

773+

}) as GatewayClient["request"];

774+

const agent = new AcpGatewayAgent(connection, createAcpGateway(request), {

775+

sessionStore,

776+

});

777+
778+

await agent.loadSession(createLoadSessionRequest("timeout-session"));

779+
780+

await expect(

781+

agent.setSessionConfigOption(

782+

createSetSessionConfigOptionRequest("timeout-session", "timeout", "180"),

783+

),

784+

).resolves.toEqual(

785+

expect.objectContaining({

786+

configOptions: expect.any(Array),

787+

}),

788+

);

789+
790+

expect(request).not.toHaveBeenCalledWith("sessions.patch", expect.anything());

791+
792+

sessionStore.clearAllSessionsForTest();

793+

});

794+
745795

it("rejects non-string ACP config option values", async () => {

746796

const sessionStore = createInMemorySessionStore();

747797

const connection = createAcpConnection();

Original file line numberDiff line numberDiff line change

@@ -58,6 +58,8 @@ const ACP_TRACE_LEVEL_CONFIG_ID = "trace_level";

5858

const ACP_REASONING_LEVEL_CONFIG_ID = "reasoning_level";

5959

const ACP_RESPONSE_USAGE_CONFIG_ID = "response_usage";

6060

const ACP_ELEVATED_LEVEL_CONFIG_ID = "elevated_level";

61+

const ACP_TIMEOUT_CONFIG_ID = "timeout";

62+

const ACP_TIMEOUT_SECONDS_CONFIG_ID = "timeout_seconds";

6163

const ACP_LOAD_SESSION_REPLAY_LIMIT = 1_000_000;

6264

const ACP_GATEWAY_DISCONNECT_GRACE_MS = 5_000;

6365

@@ -664,10 +666,12 @@ export class AcpGatewayAgent implements Agent {

664666

const sessionPatch = this.resolveSessionConfigPatch(params.configId, params.value);

665667
666668

try {

667-

await this.gateway.request("sessions.patch", {

668-

key: session.sessionKey,

669-

...sessionPatch.patch,

670-

});

669+

if (sessionPatch.patch) {

670+

await this.gateway.request("sessions.patch", {

671+

key: session.sessionKey,

672+

...sessionPatch.patch,

673+

});

674+

}

671675

this.log(

672676

`setSessionConfigOption: ${session.sessionId} -> ${params.configId}=${params.value}`,

673677

);

@@ -1291,7 +1295,7 @@ export class AcpGatewayAgent implements Agent {

12911295

value: string | boolean,

12921296

): {

12931297

overrides: Partial<GatewaySessionPresentationRow>;

1294-

patch: Record<string, string | boolean>;

1298+

patch?: Record<string, string | boolean>;

12951299

} {

12961300

if (typeof value !== "string") {

12971301

throw new Error(

@@ -1334,6 +1338,11 @@ export class AcpGatewayAgent implements Agent {

13341338

patch: { elevatedLevel: value },

13351339

overrides: { elevatedLevel: value },

13361340

};

1341+

case ACP_TIMEOUT_CONFIG_ID:

1342+

case ACP_TIMEOUT_SECONDS_CONFIG_ID:

1343+

return {

1344+

overrides: {},

1345+

};

13371346

default:

13381347

throw new Error(`ACP bridge mode does not support session config option "${configId}".`);

13391348

}

Original file line numberDiff line numberDiff line change

@@ -62,7 +62,7 @@ export function buildHelpMessage(cfg?: OpenClawConfig): string {

6262

"/think <level>",

6363

"/model <id>",

6464

"/fast status|on|off",

65-

"/verbose on|off",

65+

"/verbose on|off|full",

6666

"/trace on|off|raw",

6767

];

6868

if (isCommandFlagEnabled(cfg, "config")) {

Original file line numberDiff line numberDiff line change

@@ -746,12 +746,11 @@ export function buildBuiltinChatCommands(): ChatCommandDefinition[] {

746746

args: [

747747

{

748748

name: "mode",

749-

description: "on or off",

749+

description: "on, off, or full",

750750

type: "string",

751-

choices: ["on", "off"],

751+

choices: ["on", "off", "full"],

752752

},

753753

],

754-

argsMenu: "auto",

755754

}),

756755

defineChatCommand({

757756

key: "trace",

Original file line numberDiff line numberDiff line change

@@ -461,6 +461,15 @@ describe("commands registry args", () => {

461461

]);

462462

});

463463
464+

it("keeps verbose full available while preserving no-arg status dispatch", () => {

465+

const verbose = listChatCommands().find((command) => command.key === "verbose");

466+
467+

expect(verbose?.args?.[0]?.choices).toEqual(["on", "off", "full"]);

468+

expect(

469+

resolveCommandArgMenu({ command: verbose!, args: undefined, cfg: {} as never }),

470+

).toBeNull();

471+

});

472+
464473

it("does not show menus when arg already provided", () => {

465474

const command = createUsageModeCommand();

466475