You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 8ea5e05
Browse filesBrowse the repository at this point in the historyBrowse files
fix(everything): keep async task tools within their client task
trigger-elicitation-request-async asked the client for a 10-minute task
TTL and then polled up to 600 times one second apart, which outlasts the
TTL, so a client that honors it expired the task and the tool failed on
its last tasks/get. Polling now runs against a deadline 5 seconds short
of the TTL, measured from before the request is sent, and times out with
a report instead (modelcontextprotocol#4986).
trigger-sampling-request-async read the status message only from polls,
so a client task already failed when created was reported as "No
message". It now starts from the CreateTaskResult's statusMessage
(modelcontextprotocol#4987).
The pinning tests in tasks.test.ts now assert the fixed behavior, and
their KNOWN BUG markers are gone.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Signed-off-by: cliffhall <[email protected]>
Fix the async task tools: `trigger-elicitation-request-async` now stops polling before the 10-minute TTL it requests for the client's task runs out, instead of polling past it and failing on a task the client has expired (#4986); and `trigger-sampling-request-async` reports the status message of a client task that is already finished when it is created, instead of "No message" (#4987).
// KNOWN BUG #4987: trigger-sampling-request-async drops the status message of a task that is already finished when created; the fix changes this assertion.
426
-
it("does not poll a client task that is already finished when it is created",async()=>{
427
-
// Characterization: the status message is only read from polls, so a
428
-
// task that fails before it is returned is reported with "No message".
425
+
it("reports the status message of a client task that is already finished when it is created",async()=>{
426
+
// A task that fails before it is returned is never polled, so its status
// KNOWN BUG #4986: trigger-elicitation-request-async polls for longer than the 10-minute TTL it requests for its task; the fix changes this assertion.
590
-
it("fails on the last poll instead when the client honors the 10-minute TTL",async()=>{
591
-
// Characterization: 600 one-second polls outlast the 600000 ms TTL the
592
-
// tool asks for, so a client that expires the task on time answers the
593
-
// last tasks/get with "not found" and the call fails before the timeout
594
-
// report.
595
-
awaitconnectTaskClient(()=>{});
594
+
it("times out before a client that honors the 10-minute TTL expires the task",async()=>{
0 commit comments