SDK interrupt can now cancel queued messages and tells you which ones it cancelled.
What's wrong with this entry?
In the Agent SDK, interrupt() now accepts an options object. Passing cancelQueued: true also cancels messages waiting in the queue, and the resolved value includes a cancelled list of message ids alongside the existing still_queued. Previously it took no arguments.
cancelQueued: trueaddscancel_queued: trueto the control request sent to the CLI.- Available to any SDK caller on this build, with no flag.
- The surrounding SDK transport and query code was re-bundled from lazily loaded module wrappers into plain top-level classes, with no behaviour change.
const result = await query.interrupt({ cancelQueued: true });
console.log(result.cancelled, result.still_queued);cancel_queued
Strings lifted out of the shipped bundle, so the claim above can be checked against them.
Related
Other releases about the same thing. Found by shared names or similar wording; neither means one caused the other.
-
v2.1.219
interrupt control request can now cancel the whole queue (cancel_queued)
Both mention cancel queued
-
v2.1.219
New protocol capability interrupt_cancel_queued_v1 on system/init
Both mention cancel queued