{"version":"2.1.285","anchor":"sse-frame-stall-diagnostics-writer-only-active-when-claude","canonical_anchor":"sse-frame-stall-diagnostics-writer-only-active-when-claude","heading":"Diagnostics file can now record slow or stalled streaming responses","tier":"use","area":"Diagnostics","url":"https:\/\/changelogs.core-directive.com\/v\/2.1.285\/e\/sse-frame-stall-diagnostics-writer-only-active-when-claude","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.285","markdown":"### Diagnostics file can now record slow or stalled streaming responses\n\nWith CLAUDE_CODE_DIAGNOSTICS_FILE set, Claude Code can log a record whenever a piece of a streamed response arrives slowly\n\n**Unclear.** It is not clear whether every streamed response is watched once the diagnostics file is set, or only some.\n\n**What**\n\nThe diagnostics file set with `CLAUDE_CODE_DIAGNOSTICS_FILE` can now capture stalls in streamed responses. A streamed response arrives as a series of pieces, called frames. When a frame arrives slowly, Claude Code writes a `cli_sse_frame_stall` record noting:\n\n- the gap before the frame arrived\n\n- how far Claude Code's own processing had fallen behind\n\n- how much CPU time was used\n\nThe stall watcher is only created when `CLAUDE_CODE_DIAGNOSTICS_FILE` is set and the code reading the stream asks for it. Otherwise nothing is measured.\n\nSeparately, the waits between reconnect attempts and between retried requests are now worked out by one shared routine instead of separate calculations.\n\n**Why**\n\nThis is for troubleshooting only. Nothing changes unless you set the diagnostics file, and if you do, it gives you a way to see where a slow response was held up.\n\n- Area: Diagnostics\n- Names: `CLAUDE_CODE_DIAGNOSTICS_FILE`\n- Tier: Use it now\n- Useful: 3\/5\n- Signal: 2\/5"}