mirror of
https://github.com/microsoft/vscode.git
synced 2026-07-11 14:04:49 -05:00
The Anthropic Messages streaming body can return 200 with headers and then hang mid-stream with no further chunk and no error, leaving the for-await loop pending indefinitely. Add a 120s idle watchdog that resets on each chunk, emits a messagesApi.streamIdleTimeout telemetry event when it trips (so the stall is observable in the wild), rejects the iterator, and cancels the underlying reader so the stream settles instead of hanging.