[PR #12623] fix: Doom-loop guard for repeated reasoning/output #14294

Open
opened 2026-02-16 18:19:06 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/anomalyco/opencode/pull/12623

State: open
Merged: No


What does this PR do?

The doom loop previously only caught loops where a tool call is repeatedly called. This pr adds that same feature for reasoning and normal output.
Fixes: https://github.com/anomalyco/opencode/issues/12716

Please provide a description of the issue (if there is one), the changes you made to fix it, and why they work. It is expected that you understand why your changes work and if you do not understand why at least say as much so a maintainer knows how much to value the pr.

If you paste a large clearly AI generated description here your PR may be IGNORED or CLOSED!

How did you verify your code works?

I ran the dev cmd and it worked.
Screenshot 2026-02-07 at 13 41 34

**Original Pull Request:** https://github.com/anomalyco/opencode/pull/12623 **State:** open **Merged:** No --- ### What does this PR do? The doom loop previously only caught loops where a tool call is repeatedly called. This pr adds that same feature for reasoning and normal output. Fixes: https://github.com/anomalyco/opencode/issues/12716 Please provide a description of the issue (if there is one), the changes you made to fix it, and why they work. It is expected that you understand why your changes work and if you do not understand why at least say as much so a maintainer knows how much to value the pr. **If you paste a large clearly AI generated description here your PR may be IGNORED or CLOSED!** ### How did you verify your code works? I ran the dev cmd and it worked. <img width="1920" height="892" alt="Screenshot 2026-02-07 at 13 41 34" src="https://github.com/user-attachments/assets/490818bc-138a-4698-84dc-400da8e01b3e" />
yindo added the pull-request label 2026-02-16 18:19:06 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#14294