[BUG] "You've hit your limit" context compression fires mid-task, leaving code in a broken state.

Resolved 💬 1 comment Opened Apr 15, 2026 by lettstanley-oss Closed May 25, 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?

When Claude Code runs out of context mid-task, it silently compresses the conversation and stops editing. This can leave files partially modified — for example, a TypeScript interface updated but the JSX still referencing the old props — resulting in compile errors and a broken dev server.

There's no summary of what was completed, what changed, or what still needs to be done. The user is left with broken code and no way to know what state they're in without manually diffing every touched file.

What Should Happen?

At minimum:
(1) don't compress mid-edit — finish the current tool call sequence first,
(2) print a summary of all files changed and remaining work before compacting,
(3) if the build is broken at compression time, at least say so explicitly and why.

Error Messages/Logs

You've hit your limit · resets Apr 15, 12pm (America/Chicago)

Steps to Reproduce

  1. Use Claude code until you reach limit.
  2. One might see "You've hit your limit · resets..." or it just stops

Claude Model

Sonnet (default)

Is this a regression?

No, this never worked

Last Working Version

_No response_

Claude Code Version

2.1.101

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

IntelliJ IDEA terminal

Additional Information

I am ok with higher paid usage but sometimes just it just stopping leaves me in a place where it is difficult to really continue working.

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗