Skip to content

Increase MAX_TURNS from 50 to 75#112

Closed
ejc3 wants to merge 3 commits intoclaude-review-prompting-fixfrom
claude-increase-max-turns
Closed

Increase MAX_TURNS from 50 to 75#112
ejc3 wants to merge 3 commits intoclaude-review-prompting-fixfrom
claude-increase-max-turns

Conversation

@ejc3
Copy link
Copy Markdown
Owner

@ejc3 ejc3 commented Jan 5, 2026

Summary

Increase MAX_TURNS from 50 to 75 to allow thorough reviews of large PRs.

50 turns wasn't enough for reviewing PRs with many files - the agent would run out of turns before completing its analysis.


Stacked on: claude-review-prompting-fix (PR #110)

The Claude review agent was running out of turns when reviewing
large PRs with many files. Increased from 50 to 75 to allow
more thorough reviews.
@ejc3 ejc3 force-pushed the claude-increase-max-turns branch from 88829e7 to 3b6c63a Compare January 5, 2026 19:46
@claude-claude
Copy link
Copy Markdown
Contributor

claude-claude bot commented Jan 5, 2026

🔍 Claude Review

SEVERITY: critical

Findings

[CRITICAL] PR metadata mismatch with actual code changes

  • PR Title: "Increase MAX_TURNS from 50 to 200"
  • PR Description: "Increase MAX_TURNS from 50 to 200"
  • Commit Message: "Increase MAX_TURNS from 50 to 75"
  • Actual Code Change: Changes MAX_TURNS from 50 to 75 (line 26 in scripts/claude-assistant/index.ts)

The PR title and description claim to increase MAX_TURNS to 200, but the actual code only increases it to 75. This is a significant discrepancy that will:

  1. Mislead reviewers about the scope of the change
  2. Create confusion in the git history
  3. Under-deliver on the stated goal of "allow[ing] thorough reviews of large PRs"

Required Action: Either:

  • Update the code to actually use 200 (as claimed), OR
  • Update the PR title and description to reflect the actual value of 75

Summary

Critical mismatch between PR documentation (claiming 50→200) and actual implementation (50→75). The PR metadata must be corrected to match the code, or vice versa.


Review by Claude | Run

@claude-claude
Copy link
Copy Markdown
Contributor

claude-claude bot commented Jan 5, 2026

🔧 Auto-Fix Created

I found issues and created a fix PR: #113

The fix updates the code to actually use 200 (as stated in the PR title and description) instead of the current value of 75.

Please review and merge the fix PR first, then this PR.

View Claude Run

- Add STEP 0 to prompt: Wait for CI to pass before reviewing
- Add instructions to run lint locally (cargo fmt, clippy) before committing
- Add instructions to verify fix PRs pass CI before finishing
- Add warning about editing files directly, no temp files
- Add Rust toolchain (rustfmt, clippy) to all workflow jobs
- Add fuse-backend-rs and fuser checkouts for workspace dependencies
- Add build dependencies (libfuse3-dev, libclang-dev, clang)
- Set FUSE_BACKEND_RS and FUSER env vars for cargo

Tested: cargo fmt --check && cargo clippy --all-targets passes with new env vars
@ejc3 ejc3 changed the title Increase MAX_TURNS from 50 to 200 Increase MAX_TURNS from 50 to 75 Jan 5, 2026
Claude review: wait for CI, run lint, verify fix PRs
@claude-claude
Copy link
Copy Markdown
Contributor

claude-claude bot commented Jan 5, 2026

🔍 Claude Review

SEVERITY: medium

Findings

[MEDIUM] Lint enforcement workflow is split across multiple sections

The prompt has a "CRITICAL: IF YOU MAKE CHANGES" section (lines 256-279) that instructs Claude to:

  1. Run lint locally BEFORE committing (cargo fmt --check, cargo clippy)
  2. After pushing, verify PR passes CI

However, STEP 5 "FIX" (lines 352-408) which contains the actual commit workflow is:

  • 5a. Edit files
  • 5b. Commit (git commit -m "fix: <concise description>") ← No lint check here!
  • 5c. Push
  • 5d. Create stacked PR
  • 5e. Update original PR

Issue: The lint check instruction and commit step are in separate sections. Claude must remember to run lint (from the CRITICAL section) before executing step 5b (Commit). This split design is error-prone.

Impact: Claude might commit without running lint, leading to CI failures on fix PRs (the exact problem this PR aims to prevent).

Recommendation: Integrate the lint check directly into STEP 5:

  • 5a. Edit files
  • 5a-lint. Run lint (cargo fmt --check, cargo clippy)
  • 5b. Commit (only if lint passes)
  • 5c. Push
  • 5c-verify. Verify CI passes (gh pr checks --watch)
  • 5d. Create stacked PR
  • 5e. Update original PR

Summary

The PR correctly increases MAX_TURNS to 75 and adds valuable CI-awareness to the review workflow. However, the lint enforcement design splits the instruction across two sections, which could lead to Claude forgetting to run lint before committing.


Review by Claude | Run

@claude-claude
Copy link
Copy Markdown
Contributor

claude-claude bot commented Jan 5, 2026

🔧 Auto-Fix Created

I found issues and created a fix PR: #120

The fix integrates lint enforcement and CI verification directly into STEP 5, preventing Claude from forgetting to run lint before committing.

Please review and merge the fix PR first, then this PR.

View Claude Run

@ejc3 ejc3 deleted the branch claude-review-prompting-fix January 6, 2026 04:12
@ejc3 ejc3 closed this Jan 6, 2026
@ejc3 ejc3 deleted the claude-increase-max-turns branch January 17, 2026 03:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant