claude-code - 💡(How to fix) Fix [BUG] Repeated output more than 50 times [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#46746Fetched 2026-04-12 13:34:08
View on GitHub
Comments
1
Participants
2
Timeline
4
Reactions
0
Timeline (top)
labeled ×3commented ×1

Error Message

Error Messages/Logs

Code Example

No
RAW_BUFFERClick to expand / collapse

Preflight Checklist

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

What's Wrong?

Prompt (exact):

▎ "Review the complete project codebase and tell me what is pending on the frontend work."

Output (high-level): A structured frontend audit grouped by feature area — covering "coming soon" stubs, partially built features missing backend wiring, incomplete data flows,
and hardcoded mock data. The content quality was good.

Bug:
The response was printed to the terminal more than 50 times consecutively. The user expected a single response, as usual. The content was not streamed or paginated — it was the same complete response block, duplicated 50+ times.

Technical context:

  • Model: claude-sonnet-4-6
  • Interface: Claude Code CLI (terminal)
  • The response was generated by the main agent, which had delegated research to an Explore subagent. The subagent returned its findings once; the main agent then summarized them. The repetition occurred in the main agent's final output to the terminal.
  • Platform: macOS (darwin 25.3.0), shell: zsh

What Should Happen?

One output per query

Error Messages/Logs

No

Steps to Reproduce

Unknown

Claude Model

Sonnet (default)

Is this a regression?

Yes, this worked in a previous version

Last Working Version

No response

Claude Code Version

v2.1.101

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

No hooks that could cause repetition on my end.

extent analysis

TL;DR

The main agent's final output to the terminal is likely causing the repetition of the response, and investigating the output generation logic may help resolve the issue.

Guidance

  • Review the main agent's code to identify any loops or recursive function calls that could be causing the repetition of the response.
  • Check if the Explore subagent's findings are being properly summarized and if there are any issues with the data being returned.
  • Investigate if there are any changes in the Claude Code version (v2.1.101) that could be contributing to this regression.
  • Verify if the issue is specific to the Sonnet model or if it occurs with other models as well.

Example

No code snippet can be provided without more information about the main agent's code and the output generation logic.

Notes

The lack of steps to reproduce and error messages/logs makes it challenging to provide a more specific solution. The issue seems to be a regression, and investigating the changes made in the latest version of Claude Code may help identify the root cause.

Recommendation

Apply workaround: Investigate and modify the main agent's output generation logic to prevent repetition, as the root cause is likely related to this component.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING