What probably matters to youSection of the release
What
When a program reads Claude Code's output as a live stream through the SDK (the toolkit for driving Claude Code from your own code), each reply ends with a message_stop event. That event can now carry an optional abandoned_blocks field with two parts:
api_message_id: which reply the abandoned content belongs to
from_block_index: the position from which the content blocks (the separate pieces of a reply) were left unfinished
Claude Code fills this in on a message_stop it produces itself when the stream from the API failed, stalled or ended early. A program can use it to remove half-received content blocks that will never become part of a finished assistant message.
Why
Programs that show a reply as it streams in can now clean up the partial pieces left behind by a broken stream, instead of leaving fragments on screen that nothing will ever finish.
Read from
Names in the bundleabandoned_blocksmessage_stop
Since it was published
The entry above is what we published on the day. These lines were added later, as Anthropic's own pages caught up, and they sit beside the original rather than replacing it.
Confirmed sinceAnthropic's documentation has since written up message_stop, on Stream responses in real-time.If a stream is cut off mid-message, such as when you interrupt the turn or the connection drops, you still receive that message's `message_stop` before the turn ends. A cut text or thinking block also gets its `content_block_stop`. A cut t…agent-sdk/streaming-outputsee the edit
How sure we are
One source agreesOne thing we can check says the same as this entry.
Anthropic's documentation agreesAnthropic's documentation has since written up message_stop, on Stream responses in real-time.