Sessions may stop responding (JSONL stops being written) — Claude Code
Quick fix
Update CC Switch to the latest 4.0 release and retry. If it still hangs, temporarily bypass CC Switch and submit complete reproduction details.
Symptom
Section titled “Symptom”会话有概率停止响应(JSONL 不再写入,不再发新 API 请求,UI 冻结)。Sessions may stop responding (JSONL stops being written, no new API requests are sent, and the UI freezes).
In routing mode on CC Switch v3.16.2, a DeepSeek-compatible Anthropic provider undergoes thinking-history normalization. When an assistant history message contains `tool_use` but has no `thinking` or only empty `thinking`, the system may pre-inject a synthetic `"tool call"` thinking block. The reporter observed that after `cache_read` exceeded about 150k tokens in a long session, the main response frequently entered `thinking` blocks, visible `text` blocks became nearly empty, and the session could then stop responding.
After bypassing CC Switch, the reporter did not observe the issue again with 300k+ `cache_read`. This makes CC Switch request transformation a likely trigger, but the issue did not establish that all DeepSeek-compatible Anthropic endpoints had removed the thinking backpass constraint. A reactive injection approach was submitted in PR #4210, but the issue was closed after timing out without new reproduction details. It was not confirmed that the PR was merged or that the issue was fixed. A maintainer said that 4.0 substantially refactored the related functionality and recommended updating and retesting.
Update CC Switch to the latest 4.0 release, then retest with the same DeepSeek-compatible Anthropic provider and long-session procedure.
Check whether the main response still enters `thinking` blocks and whether JSONL writes, API requests, and the UI stop again after about 3 minutes of inactivity or continued long-context conversation.
If the issue still occurs after updating, temporarily bypass CC Switch. After bypassing CC Switch while keeping the rest of the upstream path unchanged, the reporter no longer observed 400, thinking/text collapse, or session freezes.
If the issue persists, submit the CC Switch version, operating system, complete reproduction steps, and relevant logs or screenshots again.
Affected Versions
Section titled “Affected Versions”Source Issues
Section titled “Source Issues”This page is distilled from 1 real issues
(No FAQ yet)
Related problems
Section titled “Related problems”This is an unofficial community wiki with no affiliation to the cc-switch authors or the project itself. Its content is compiled from the project's public GitHub issues. This site distributes no software.