{"version":"2.1.318","anchor":"turn-streaming-failed-api-error-messages-are-closed-properl","canonical_anchor":"turn-streaming-failed-api-error-messages-are-closed-properl","heading":"Streamed output ends cleanly when the API returns an error","tier":"notice","area":"Streaming","scope":"individual","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.318\/e\/turn-streaming-failed-api-error-messages-are-closed-properl","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.318","markdown":"### Streamed output ends cleanly when the API returns an error\n\nWhen an API error ends a step, Claude Code now closes the streamed output and marks that step as failed\n\n**What**\n\nWhen a reply step ends with an error from the API, Claude Code now treats it as a failed step. It closes any parts of the output still open, marks the step as failed, and skips the final closing piece. There is also a new way to cut a step short that closes any open parts.\n\n**Why**\n\nStreamed output stays well formed after an API error.\n\n- Area: Streaming\n- Tier: You'll notice\n- Useful: 2\/5\n- Signal: 1\/5\n- Scope: individual\n- Heads-up: no"}