/compact blocked by the same tier gate that caused the overflow, leaving sessions unrecoverable
What's wrong
When a session's context exceeds 200K tokens, both auto-compact and manual /compact fail with:
Error: Error during compaction: API Error: Usage credits required for 1M context · turn on usage credits at claude.ai/settings/usage, or use --model to switch to standard context
This is circular: the session overflowed into 1M territory, and the only tool that would compact it back below 200K requires 1M context credits to run. The user is stranded — they cannot continue the session and cannot compact it.
Steps to reproduce
- Run a long session on the 200K standard context tier without usage credits enabled
- Let context exceed 200K (auto-compact failure, or manual compaction missed)
- Attempt
/compact— fails with the 1M credits error - No recovery path exists; must start a new session and lose all context
What should happen
/compact is a shrink operation. It should never require extended-context credits to execute, since its purpose is to escape overflow, not to use the extended tier. The compaction summarization should be permitted — or at minimum fall back to a truncation strategy — rather than being gated behind the feature that caused the problem.
Related — why this is not a duplicate of any of them
The upstream failure (auto-compact not triggering) is covered by #63015, #64904, #64037, #17761, and a cluster of CLAUDE_AUTOCOMPACT_PCT_OVERRIDE issues (#64773, #63627, #57627, #57567, #56666, #53801, #52390, #36381). This issue is distinct: it is about what happens after that failure. Once context has overflowed past 200K, the recovery tool /compact is itself blocked by the same tier gate, creating a deadlock. None of the above issues report /compact being unavailable as a fallback; #64037 notes the absence of a recovery path but does not identify the mechanism. The bug filed here is specifically that compaction — a shrink operation — requires extended-context credits to execute, which is circular when invoked to escape overflow.
Environment
- Platform: macOS
- Version: v2.1.158
- Model: claude-sonnet-4-6
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗