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

推荐订阅源

C
Check Point Blog
J
Java Code Geeks
H
Hackread – Cybersecurity News, Data Breaches, AI and More
D
Docker
腾讯CDC
The GitHub Blog
The GitHub Blog
大猫的无限游戏
大猫的无限游戏
Microsoft Security Blog
Microsoft Security Blog
GbyAI
GbyAI
Stack Overflow Blog
Stack Overflow Blog
博客园 - 司徒正美
T
The Blog of Author Tim Ferriss
Vercel News
Vercel News
P
Proofpoint News Feed
雷峰网
雷峰网
博客园_首页
B
Blog RSS Feed
Microsoft Azure Blog
Microsoft Azure Blog
爱范儿
爱范儿
V
V2EX
F
Fortinet All Blogs
酷 壳 – CoolShell
酷 壳 – CoolShell
MyScale Blog
MyScale Blog
S
SegmentFault 最新的问题

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
test(qa): harden Matrix tool progress live check · opencl...
vincentkoc · 2026-05-04 · via Recent Commits to openclaw:main

@@ -24,6 +24,7 @@ import {

2424

buildMatrixReplyArtifact,

2525

buildMatrixReplyDetails,

2626

buildMentionPrompt,

27+

doesMatrixQaReplyBodyMatchToken,

2728

createMatrixQaDriverScenarioClient,

2829

createMatrixQaScenarioClient,

2930

isMatrixQaExactMarkerReply,

@@ -754,6 +755,43 @@ function buildMatrixQaToolProgressTimeoutMessage(params: {

754755

].join("\n");

755756

}

756757758+

function buildMatrixQaToolProgressFinalTimeoutMessage(params: {

759+

cause: unknown;

760+

events: MatrixQaObservedEvent[];

761+

previewEventId: string;

762+

roomId: string;

763+

startIndex: number;

764+

sutUserId: string;

765+

token: string;

766+

}) {

767+

const candidates = params.events

768+

.slice(params.startIndex)

769+

.filter((event) => {

770+

if (

771+

event.roomId !== params.roomId ||

772+

event.sender !== params.sutUserId ||

773+

event.type !== "m.room.message" ||

774+

!isMatrixQaMessageLikeKind(event.kind)

775+

) {

776+

return false;

777+

}

778+

return event.relatesTo?.eventId === params.previewEventId;

779+

})

780+

.slice(-8);

781+

const candidateDetails =

782+

candidates.length === 0

783+

? ["observed final candidates: <none>"]

784+

: ["observed final candidates:", ...candidates.map(describeMatrixQaToolProgressCandidate)];

785+

return [

786+

params.cause instanceof Error

787+

? params.cause.message

788+

: `Matrix tool progress final wait failed: ${String(params.cause)}`,

789+

`preview event: ${params.previewEventId}`,

790+

`expected token: ${params.token}`,

791+

...candidateDetails,

792+

].join("\n");

793+

}

794+757795

async function runMatrixToolProgressScenario(

758796

context: MatrixQaScenarioContext,

759797

params: {

@@ -824,19 +862,33 @@ async function runMatrixToolProgressScenario(

824862

assertMatrixQaToolProgressMentionsInert(progress.event);

825863

}

826864827-

const finalized = await client.waitForRoomEvent({

828-

observedEvents: context.observedEvents,

829-

predicate: (event) =>

830-

event.roomId === context.roomId &&

831-

event.sender === context.sutUserId &&

832-

isMatrixQaMessageLikeKind(event.kind) &&

833-

event.relatesTo?.relType === "m.replace" &&

834-

event.relatesTo.eventId === preview.event.eventId &&

835-

event.body === params.finalText,

836-

roomId: context.roomId,

837-

since: progress.since,

838-

timeoutMs: context.timeoutMs,

839-

});

865+

const finalized = await client

866+

.waitForRoomEvent({

867+

observedEvents: context.observedEvents,

868+

predicate: (event) =>

869+

event.roomId === context.roomId &&

870+

event.sender === context.sutUserId &&

871+

isMatrixQaMessageLikeKind(event.kind) &&

872+

event.relatesTo?.relType === "m.replace" &&

873+

event.relatesTo.eventId === preview.event.eventId &&

874+

doesMatrixQaReplyBodyMatchToken(event, params.finalText),

875+

roomId: context.roomId,

876+

since: progress.since,

877+

timeoutMs: context.timeoutMs,

878+

})

879+

.catch((err: unknown) => {

880+

throw new Error(

881+

buildMatrixQaToolProgressFinalTimeoutMessage({

882+

cause: err,

883+

events: context.observedEvents,

884+

previewEventId: preview.event.eventId,

885+

roomId: context.roomId,

886+

startIndex: startObservedIndex,

887+

sutUserId: context.sutUserId,

888+

token: params.finalText,

889+

}),

890+

);

891+

});

840892

const unexpectedWorkingEvents = findMatrixQaUnexpectedWorkingEvents({

841893

events: context.observedEvents,

842894

finalEventId: finalized.event.eventId,