ci(auto-fix-issue): Raise turn limit to 80 and tighten prompt#21001
Open
mydea wants to merge 3 commits into
Open
ci(auto-fix-issue): Raise turn limit to 80 and tighten prompt#21001mydea wants to merge 3 commits into
mydea wants to merge 3 commits into
Conversation
Bumps `--max-turns` from 50 to 80 and adds explicit turn-budget guidance to the prompt so Claude aborts and posts a comment well before hitting the hard cap, instead of failing the action with "Reached maximum number of turns". Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Adds explicit guidance to the auto-fix prompt to plan before acting, batch parallel tool calls, avoid redundant reads/test runs, and stop searching once an answer is found. Complements the 80-turn budget by reducing the chance of running into it in the first place. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit f5d02f1. Configure here.
--max-turns counts agent turns (assistant messages), not individual tool calls. A single turn can contain many parallel tool calls and counts as one. Rephrasing the budget and economy guidance to match, so Claude self-regulates against the correct unit and is not penalized for the batching the same prompt encourages. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
The
auto-fix-issueworkflow was failing withReached maximum number of turns (50)because Claude hit the hard cap before either landing a fix or aborting cleanly. Two changes:--max-turnsfrom 50 to 80 so larger but still tractable fixes can complete.The net effect: fewer wasted turns per run, and when the issue is genuinely too big the action reports a useful issue comment instead of failing with a stack trace.