[BUG]

Resolved 💬 3 comments Opened Apr 10, 2026 by LegendsOfTheGame Closed Apr 14, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

A single debugging session consumed 88% of the Pro plan session limit during off-peak hours. The session involved iterative diagnosis of a PDF text justification problem in a Rust/printpdf project. Each iteration required reading a ~3,500-line main.rs file, which was re-read or re-summarized multiple times as the context window filled and was compressed. The high consumption felt disproportionate to the actual work done — approximately 5-6 substantive code edits were made, but the session hit near-limit usage.

What Should Happen?

Iterative debugging sessions that re-read the same large file multiple times should not consume session limits at a rate that makes complex debugging impractical on the Pro plan. Either context compression should more aggressively deduplicate repeated file reads, or the session limit should reset/count differently for re-read content.

Error Messages/Logs

Steps to Reproduce

Open a project with a large source file (3,000+ lines, e.g. a Rust main.rs)
Begin debugging a complex issue that requires multiple diagnostic hypotheses (e.g. PDF rendering behavior)
Each hypothesis requires re-reading the same file sections and making a small edit
After 5–8 read/edit/test cycles, observe session usage — it will be disproportionately high relative to the number of actual edits made
Note: the file was re-summarized via context compression mid-session, triggering additional token overhead

Claude Model

Sonnet (default)

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

Claude 1.1617.0 (8d6345) 2026-04-09T16:10:15.000Z

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

Other

Additional Information

The /insights report for this project confirms the pattern: large Rust files are re-read many times across iterative debugging sessions. Context compression mid-session appears to trigger re-summarization of already-read content, multiplying token cost without proportional value. The specific session involved diagnosing Helvetica AFM glyph width metrics in printpdf — a problem that required 4–5 hypothesis/test cycles, each re-reading the same ~200-line function.

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗