Rate limit terminates active session with no save opportunity — silent data loss
Status Closed — duplicate
Maintainer reply None cached
Workaround ✓ Mentioned in description ↑
Activity 4 comments · opened Feb 14, 2026 · closed Feb 18, 2026
Description
When the weekly usage limit is reached during an active Claude Code session, the session is terminated immediately with a red error message. The AI model receives no warning and no final turn to save work in progress.
This causes:
- Silent data loss — any work done since the last manual save is gone
- No log entry — the session log is not updated because the model never gets a chance to write
- No session transcript — crash recovery transcripts are also lost
- No forensic trail — after the fact, there is zero evidence of what was happening when the session died
Impact
- User missed a real-world deadline because they were locked out for the rest of the week
- User had been running ~14 Opus sessions across 3 days (complex data ingestion project with 5.7M+ DB rows) and had no visibility into how fast quota was being consumed
- The red limit message was the first and only indication — no progressive warnings
- User believed they were at ~50% usage (based on Claude Desktop dashboard), but Code hit 100%. It's unclear if Desktop and Code share the same quota pool or if there's a metering discrepancy.
Expected Behavior
- Progressive warnings: At 50%, 75%, 90% of weekly quota, show a visible warning in the CLI (yellow/orange) so the user can plan around it
- Graceful shutdown: When the limit is about to be hit (e.g., <2% remaining), give the AI model ONE final turn to save state, update logs, and commit — before terminating
- Usage visibility: Provide a command (
claude usageor similar) that shows current weekly consumption, remaining quota, and reset date - Per-session cost estimate: Show approximate quota consumed per session so users can gauge burn rate
- Desktop vs Code quota clarity: Make it clear whether Desktop and Code share the same pool, and show unified usage across both
Current Workaround
User has written extensive context-window-aware save instructions in CLAUDE.md (checkpoint at 75%, wind down at 85%, hard stop at 90%), but these only protect against context window exhaustion — not platform rate limits, which kill the session externally with no warning to the model.
Environment
- Windows 11 Pro 10.0.26200
- Claude Code CLI (Opus 4.6 model)
- ~14 sessions over 3 days across 3 projects
- Max subscription (weekly quota model)
- Stats: 21 sessions, 8,163 messages, 1,401 tool calls, 209M cache-read tokens in 4 days
🤖 Generated with Claude Code
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗