You'll noticeTier: how much it should matter to you
2Useful: my rating, 1 to 5
1Signal: worth watching, 1 to 5
AgentsArea: what it touches
ImprovementsKind: in v2.1.307,
ImprovementsSection of the release
What
Headless mode means running Claude Code with no interactive screen, for example from a script or through the Agent SDK. When you interrupt in this mode, Claude Code now deals with the message it was working on in one of two ways:
With cancelQueued set, that message is finished off along with the cancelled queue.
Without cancelQueued, the message goes back into the queue, is marked as already sent, and a "queued" event is reported for it.
An interrupt no longer drops the message that was being handled.
Why
Prompts sent through the SDK or a script are no longer lost when you interrupt. If you do not want them to come back, pass cancelQueued.