claude-code icon indicating copy to clipboard operation
claude-code copied to clipboard

[BUG] Internal compacting/summarization process hung indefinitely

Open mhcoen opened this issue 9 months ago โ€ข 2 comments

Environment

  • Platform (select one):
    • [x] Anthropic API
    • [ ] AWS Bedrock
    • [ ] Google Vertex AI
    • [ ] Other:
  • Claude CLI version: 1.0.35 (Claude Code)
  • Operating System: macOS (Darwin 24.5.0)
  • Terminal: Claude Code interface

Bug Description

Internal compacting/summarization process hung indefinitely, consuming entire Opus usage quota without user interaction or actual conversation progress.

Steps to Reproduce

  1. Had a long conversation about code refactoring and bug fixes prior to the 5-usage reset and the compacting mentioned in 2 & 3.
  2. System initiated internal compacting/summarization process shortly after the reset.
  3. Compacting process hung and consumed tokens continuously
  4. User eventually interrupted compacting manually with ctrl-c
  5. User's entire Opus usage quota for the period was depleted according to the user-interface.

Expected Behavior

Internal compacting should complete quickly without consuming significant tokens, or fail gracefully with an error message.

Actual Behavior

Compacting process hung indefinitely, continuously consuming Opus tokens until the user's entire usage quota was exhausted. No error message or timeout occurred.

Additional Context

  • This was a system-internal process failure, not related to user code or actions
  • The conversation was about debugging Python CLI code (episodic project)
  • User reports: "Your internal compacting is what hung. it had nothing to with my code and consumed all my usage for this period"
  • Date: 2025-06-26
  • Request: Restoration of consumed Opus usage quota

mhcoen avatar Jun 26 '25 01:06 mhcoen

Something else is going on here. This may be a bug in the Claude Code CLI.

After the difficulties described above, the terminal displayed Approaching Opus usage limit ยท /model to use best available model.

However, that was more that 2.5 hours ago and I have continued using the CLI extensively. It still hasn't said I've exhauted my usage of claude-opus-4-20250514.

mhcoen avatar Jun 26 '25 04:06 mhcoen

This is potentially related to #2651. If you specifically ask it to run /compact like /compact we're having problems with long compact outputs, write smaller to-the-point summaries it should help circumvent the issue.

ShitizZip avatar Jun 27 '25 04:06 ShitizZip

Thank you for the response!

mhcoen avatar Jul 09 '25 05:07 mhcoen

Found 3 possible duplicate issues:

  1. https://github.com/anthropics/claude-code/issues/2391
  2. https://github.com/anthropics/claude-code/issues/2283
  3. https://github.com/anthropics/claude-code/issues/2222

This issue will be automatically closed as a duplicate in 3 days.

  • If your issue is a duplicate, please close it and ๐Ÿ‘ the existing issue instead
  • To prevent auto-closure, add a comment or ๐Ÿ‘Ž this comment

๐Ÿค– Generated with Claude Code

github-actions[bot] avatar Aug 16 '25 06:08 github-actions[bot]

This issue has been automatically closed as a duplicate of #2391.

If this is incorrect, please re-open this issue or create a new one.

๐Ÿค– Generated with Claude Code

github-actions[bot] avatar Aug 21 '25 09:08 github-actions[bot]

This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.

github-actions[bot] avatar Aug 29 '25 14:08 github-actions[bot]