Unclear It is not confirmed that the server honours the request for long-poll responses.
What
Remote sessions receive updates over a streaming connection (SSE, a single long-lived connection the server keeps sending data down). Some proxies hold back that data, so the connection looks silent. The CCR SSE connection used by remote sessions now has a fallback to long polling, where the client asks the server for a response, the server answers and closes, and the client immediately asks again.
- The connection counts, per connection, how many body bytes arrived and how many connections in a row closed without delivering anything (
bodyBytesThisConnection,silentConnectionStreak). - After a run of silent connections it switches into long-poll mode (
longPollMode) and asks the server for long-poll responses on later connects (askedLongPollThisConnection). The message it records says it is "asking the server for long-poll responses (a proxy may be buffering the response body)". - When a long-poll connection finishes cleanly and either moved the conversation forward or ran past a time limit, it logs
SSETransport: Long poll completed, reopeningand reopens at once instead of going through the normal reconnect path. Before, a stream ending always loggedSSETransport: Stream ended, reconnecting. - Redials in long-poll mode are quiet (
quietRedial) and skip the usual connection reporting. - The timeout that decides a connection is dead now allows for the long-poll interval the server reports back. Before, it was
keepaliveIntervalMs()plus a fixed margin. - The environment variable
CLAUDE_CODE_CCR_LONG_POLLoverrides the behaviour:trueforces long polling,falseturns it off. - Without that variable, the new
longPollFallbackoption decides. It is set only when the client owns the process, a further check passes, and the gatetengu_ccr_sse_long_poll_fallbackallows it. Nothing has been read about that gate's value.
Why
If your network sits behind a proxy that buffers streamed responses, a remote session could appear to hang or keep reconnecting. This fallback gives such connections another way to get updates, and CLAUDE_CODE_CCR_LONG_POLL lets you force it on or off yourself.
tengu_ccr_sse_long_poll_fallback Not enough to sayNothing here resolved what this flag was doing on this version, so nothing here should be read as on or off.
This account: no value returned · anonymous baseline: no value returned · compiled default in v2.1.314: on
These values were read against a different version of Claude Code, so treat them as the nearest reading available instead of one taken on this release.
Read once, for one account on one subscription tier, against v2.1.314. It isn't a statement about your account. What a flag value here can and cannot tell you
It is not confirmed that the server honours the request for long-poll responses.
New in this build: tengu_ccr_sse_long_poll_fallback