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

推荐订阅源

I
InfoQ
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Apple Machine Learning Research
Apple Machine Learning Research
月光博客
月光博客
B
Blog
罗磊的独立博客
GbyAI
GbyAI
博客园 - 三生石上(FineUI控件)
雷峰网
雷峰网
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
Microsoft Security Blog
Microsoft Security Blog
宝玉的分享
宝玉的分享
The GitHub Blog
The GitHub Blog
人人都是产品经理
人人都是产品经理
博客园 - Franky
有赞技术团队
有赞技术团队
WordPress大学
WordPress大学
博客园 - 聂微东
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
V
Visual Studio Blog
MyScale Blog
MyScale Blog
Google DeepMind News
Google DeepMind News
G
Google Developers Blog
aimingoo的专栏
aimingoo的专栏

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(matrix): replace recovered command progress lines (#8...
bdjben · 2026-06-15 · via Recent Commits to openclaw:main

@@ -2950,12 +2950,24 @@ describe("matrix monitor handler draft streaming", () => {

29502950

) => Promise<void> | void;

29512951

onAssistantMessageStart?: () => void;

29522952

suppressDefaultToolProgressMessages?: boolean;

2953-

onToolStart?: (payload: { name?: string }) => Promise<void>;

2953+

onToolStart?: (payload: {

2954+

itemId?: string;

2955+

toolCallId?: string;

2956+

name?: string;

2957+

phase?: string;

2958+

args?: Record<string, unknown>;

2959+

detailMode?: "explain" | "raw";

2960+

}) => Promise<void>;

29542961

onItemEvent?: (payload: {

2962+

itemId?: string;

2963+

toolCallId?: string;

29552964

progressText?: string;

29562965

summary?: string;

29572966

title?: string;

29582967

name?: string;

2968+

kind?: string;

2969+

phase?: string;

2970+

status?: string;

29592971

}) => Promise<void>;

29602972

onPlanUpdate?: (payload: {

29612973

phase: string;

@@ -2964,15 +2976,24 @@ describe("matrix monitor handler draft streaming", () => {

29642976

}) => Promise<void>;

29652977

onApprovalEvent?: (payload: { phase: string; command?: string }) => Promise<void>;

29662978

onCommandOutput?: (payload: {

2979+

itemId?: string;

2980+

toolCallId?: string;

29672981

phase: string;

29682982

name?: string;

29692983

exitCode?: number;

2984+

status?: string;

29702985

title?: string;

29712986

}) => Promise<void>;

29722987

onPatchSummary?: (payload: {

2988+

itemId?: string;

2989+

toolCallId?: string;

29732990

phase: string;

2991+

name?: string;

29742992

summary?: string;

29752993

title?: string;

2994+

added?: string[];

2995+

modified?: string[];

2996+

deleted?: string[];

29762997

}) => Promise<void>;

29772998

disableBlockStreaming?: boolean;

29782999

};

@@ -3138,6 +3159,167 @@ describe("matrix monitor handler draft streaming", () => {

31383159

await finish();

31393160

});

314031613162+

it("replaces recovered Matrix command progress instead of leaving stale failed text", async () => {

3163+

const { dispatch } = createStreamingHarness({

3164+

streaming: "progress",

3165+

previewToolProgressEnabled: true,

3166+

accountConfig: {

3167+

streaming: { mode: "progress", progress: { label: "Working" } },

3168+

} as never,

3169+

});

3170+

const { opts, finish } = await dispatch();

3171+3172+

await opts.onItemEvent?.({

3173+

itemId: "command-1",

3174+

kind: "command",

3175+

name: "exec",

3176+

phase: "end",

3177+

status: "failed",

3178+

progressText: "run openclaw cron -> run jq (agent) failed",

3179+

});

3180+

await opts.onItemEvent?.({

3181+

itemId: "command-1",

3182+

kind: "command",

3183+

name: "exec",

3184+

phase: "end",

3185+

status: "failed",

3186+

progressText: "run openclaw cron -> run jq (agent) failed",

3187+

});

3188+3189+

await vi.waitFor(() => {

3190+

expect(sendSingleTextMessageMatrixMock).toHaveBeenCalledTimes(1);

3191+

});

3192+

expect(singleTextMessageBody()).toContain("failed");

3193+3194+

await opts.onCommandOutput?.({

3195+

itemId: "command-1",

3196+

toolCallId: "call-1",

3197+

phase: "end",

3198+

name: "exec",

3199+

status: "completed",

3200+

exitCode: 0,

3201+

});

3202+3203+

await finish();

3204+

expect(editMessageMatrixMock).toHaveBeenCalledWith(

3205+

"!room:example.org",

3206+

"$draft1",

3207+

expect.stringContaining("completed"),

3208+

expect.any(Object),

3209+

);

3210+

const recoveredEdit = mockCalls(editMessageMatrixMock, "editMessageMatrix").find(

3211+

([, eventId, body]) =>

3212+

eventId === "$draft1" && typeof body === "string" && body.includes("completed"),

3213+

);

3214+

expect(recoveredEdit?.[2]).not.toContain("failed");

3215+

expect(recoveredEdit?.[2]).not.toContain("run openclaw cron -> run jq");

3216+

});

3217+3218+

it("replaces Matrix tool-start progress when command output completes", async () => {

3219+

const { dispatch } = createStreamingHarness({

3220+

streaming: "progress",

3221+

previewToolProgressEnabled: true,

3222+

accountConfig: {

3223+

streaming: { mode: "progress", progress: { label: "Working" } },

3224+

} as never,

3225+

});

3226+

const { opts, finish } = await dispatch();

3227+3228+

await opts.onToolStart?.({

3229+

itemId: "fc-call-2",

3230+

toolCallId: "call-2",

3231+

name: "exec",

3232+

phase: "start",

3233+

args: { command: "npm install" },

3234+

});

3235+

await opts.onToolStart?.({

3236+

itemId: "fc-call-2",

3237+

toolCallId: "call-2",

3238+

name: "exec",

3239+

phase: "update",

3240+

args: { command: "npm install" },

3241+

});

3242+3243+

await vi.waitFor(() => {

3244+

expect(sendSingleTextMessageMatrixMock).toHaveBeenCalledTimes(1);

3245+

});

3246+

expect(singleTextMessageBody()).toContain("install dependencies");

3247+3248+

await opts.onItemEvent?.({

3249+

itemId: "fc-call-2",

3250+

toolCallId: "call-2",

3251+

kind: "command",

3252+

name: "exec",

3253+

phase: "update",

3254+

progressText: "install dependencies",

3255+

});

3256+3257+

await opts.onCommandOutput?.({

3258+

itemId: "fc-call-2-output",

3259+

toolCallId: "call-2",

3260+

phase: "end",

3261+

name: "exec",

3262+

status: "completed",

3263+

exitCode: 0,

3264+

});

3265+3266+

await finish();

3267+

const completedEdit = mockCalls(editMessageMatrixMock, "editMessageMatrix").find(

3268+

([, eventId, body]) =>

3269+

eventId === "$draft1" && typeof body === "string" && body.includes("completed"),

3270+

);

3271+

expect(completedEdit?.[2]).not.toContain("install dependencies");

3272+

});

3273+3274+

it("replaces Matrix patch progress when the patch summary completes", async () => {

3275+

const { dispatch } = createStreamingHarness({

3276+

streaming: "progress",

3277+

previewToolProgressEnabled: true,

3278+

accountConfig: {

3279+

streaming: { mode: "progress", progress: { label: "Working" } },

3280+

} as never,

3281+

});

3282+

const { opts, finish } = await dispatch();

3283+3284+

await opts.onItemEvent?.({

3285+

itemId: "patch:call-3",

3286+

toolCallId: "call-3",

3287+

kind: "patch",

3288+

name: "apply_patch",

3289+

phase: "update",

3290+

progressText: "updating Matrix progress handling",

3291+

});

3292+

await opts.onItemEvent?.({

3293+

itemId: "patch:call-3",

3294+

toolCallId: "call-3",

3295+

kind: "patch",

3296+

name: "apply_patch",

3297+

phase: "update",

3298+

progressText: "updating Matrix progress handling",

3299+

});

3300+3301+

await vi.waitFor(() => {

3302+

expect(sendSingleTextMessageMatrixMock).toHaveBeenCalledTimes(1);

3303+

});

3304+

expect(singleTextMessageBody()).toContain("updating Matrix progress handling");

3305+3306+

await opts.onPatchSummary?.({

3307+

itemId: "patch:call-3",

3308+

toolCallId: "call-3",

3309+

phase: "end",

3310+

name: "apply_patch",

3311+

modified: ["extensions/matrix/src/matrix/monitor/handler.ts"],

3312+

summary: "1 file modified",

3313+

});

3314+3315+

await finish();

3316+

const patchEdit = mockCalls(editMessageMatrixMock, "editMessageMatrix").find(

3317+

([, eventId, body]) =>

3318+

eventId === "$draft1" && typeof body === "string" && body.includes("1 file modified"),

3319+

);

3320+

expect(patchEdit?.[2]).not.toContain("updating Matrix progress handling");

3321+

});

3322+31413323

it("keeps Matrix tool progress mentions inside code formatting", async () => {

31423324

const { dispatch } = createStreamingHarness({

31433325

previewToolProgressEnabled: true,