Repository navigation
Tests: client-tools fixture on real state, hydration-budget and durable-pause rows, think-session - #3564
Tests: client-tools fixture on real state, hydration-budget and durable-pause rows, think-session#3564mattzcarey wants to merge 5 commits into
Conversation
|
agents
@cloudflare/ai-chat
@cloudflare/codemode
hono-agents
@cloudflare/shell
@cloudflare/think
@cloudflare/voice
@cloudflare/worker-bundler
commit: |
|
✅ agents import sizes: no significant changes ( |
| const read = ( | ||
| this as unknown as { | ||
| _chatWaitsForTest?: () => { | ||
| applying: boolean; | ||
| continuationRequestId: string | null; | ||
| parked: boolean; | ||
| }; | ||
| } | ||
| )._chatWaitsForTest; | ||
| return typeof read === "function" ? read.call(this) : undefined; |
There was a problem hiding this comment.
🔍 Harness wait-state hook missing at head
The harness-backed Think defines no _chatWaitsForTest, so guarded tests skip the new wait-state checks. The stall-recovery test calls the reader directly and fails before checking the recovered reply.
Was this helpful? React with 👍 or 👎 to provide feedback.
| "test": "Think — tool results with nothing to continue > a clear while the reply is being stored keeps it out of the cleared chat", | ||
| "reason": "runs the clear inside the class's private `_rememberPendingResponseHook` (`clearDuringNextReplyStoreForTest`); the successor clears through the public `clearMessages()` while the reply streams and asserts the same outcome: nothing stored, and no response hook", | ||
| "successor": { | ||
| "file": "client-tools.test.ts", | ||
| "test": "Think — tool results with nothing to continue > a clear while the reply streams keeps it out of the cleared chat" |
There was a problem hiding this comment.
🔍 Clear test misses final-save window
The successor calls clearMessages() after a text delta, not during the pending response hook. It can pass without exercising the reset check immediately before the completed reply is saved.
Was this helpful? React with 👍 or 👎 to provide feedback.
| // A continuation still to start, on either Think: the public wait (no | ||
| // reply in this file waits on a client when it settles). | ||
| await agent.waitUntilStableForTest({ timeout: 5000 }); |
There was a problem hiding this comment.
🔍 Reconciliation tests ignore stability timeouts
settled() returns normally when waitUntilStable times out. The assertions then read the transcript without knowing whether pending work finished.
Was this helpful? React with 👍 or 👎 to provide feedback.
…s chat waits where it offers them Unit: slim/finish-hollow-6 @4f13dead3 (rv-2; tests; 4 commits)
…st, on its socket twin Unit: slim/parity2-hb-2 @1a53e765a (rv-2; record; on land-hb-long-path)
…a tab drives over a WebSocket request (harness's echoed-row unit makes it pass on the harness-backed Think) Unit: slim/parity-actions-26 @c9a9f79e1 (rv-2 at ee7cdbc07, carried: position only)
…orded as skipped by the user, through a real reset (G18-1's second test); its class row Unit: slim/land-ts-22-2 @fa5e22713 (rv-2 at cb454c858, carried)
…-only; its successor is the public batch test test(think): client-tools rows for the two cancelAllChats tests that read a class private, on their public successors test(think): client-tools: public successors and rows for three class-latch tests (a continuation whose repair throws; a tab's stop of a continuation parked on a sibling; a clear while the reply streams) Unit: slim/finish-ct-flip-1 @9d3b07c69 (rv-2; its top 3 commits; the lower 4 are finish-hollow-6, already in)
2945803 to
4cdbe98
Compare
Stacked on #3562 (the shell PR): these tests and records follow its changes. Retargeted to main when it merges. Tests and score records only; no product code.
2d39ec07btest(think): the client-tools fixture reads the harness-backed Think's chat waits where it offers them7d3095771harness-class-only: hydration-budget's private long-path reconcile test, on its socket twin0f36451f2test(think): the Reused tool-call IDs can overwrite assistant messages during reconciliation #1992 echoed-row test class-only on the public test a tab drives over a WebSocket request (harness's echoed-row unit makes it pass on the harness-backed Think)725288030test(think): a stopped recovery attempt whose model then fails is recorded as skipped by the user, through a real reset (G18-1's second test); its class row