Where does the bug appear (feature/product)?
Cursor CLI
Describe the Bug
The Cursor CLI stops or enters an infinite loop when executing a code review prompt.
Steps to Reproduce
- Using the cursor-agent with the code review prompt causes an infinite loop.
- cmd+c
- If I type “continue”, the cursor-agent also gets stuck in the loop.
Expected Behavior
Execute the prompt correctly.
Operating System
MacOS
Current Cursor Version (Menu → About Cursor → Copy)
Version: 1.7.39 (Universal)
VSCode Version: 1.99.3
Commit: a9c77ceae65b77ff772d6adfe05f24d8ebcb2790
Date: 2025-10-08T00:33:20.352Z
Electron: 34.5.8
Chromium: 132.0.6834.210
Node.js: 20.19.1
V8: 13.2.152.41-electron.0
OS: Darwin arm64 24.2.0
For AI issues: which model did you use?
sonnet 4.5
Additional Information
I’m using the follow prompt, and causing same problem everytime.
You are an expert technical writer. Think carefully and systematically about updating this Pull Request description.
## PR Information
- Repository: {owner}/{repo}
- PR #{number}: {title}
- URL: {url}
- Target branch: {baseBranch}
- Source branch: {headBranch}
## Update Process
### Step 1: Analysis
First, examine the code changes to understand:
- **Purpose**: What problem does this PR solve?
- **Scope**: What files and functionality are affected?
- **Impact**: How does this change the user/developer experience?
- **Dependencies**: Are there related changes or requirements?
### Step 2: Generate Description
Create a comprehensive PR description following this structure:
<!-- AI_TEMPLATE_START: This is a structured PR description template for AI processing -->
## Summary
<!-- AI_INSTRUCTION: Provide a clear, concise explanation of what changed and why. Focus on the business value and technical impact. -->
[Describe the main purpose and goals of this PR]
### Key Changes
<!-- AI_INSTRUCTION: List the most important changes made in this PR. Use bullet points for clarity. -->
- [Change 1: Brief description]
- [Change 2: Brief description]
- [Change 3: Brief description]
## Type of Change
<!-- AI_INSTRUCTION: Check ALL applicable boxes based on the code changes. Use [x] to mark selected items. -->
- [ ] 🐛 Bug fix (non-breaking change which fixes an issue)
- [ ] ✨ New feature (non-breaking change which adds functionality)
- [ ] 💥 Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] 📚 Documentation update
- [ ] ♻️ Refactoring (no functional changes)
- [ ] 🎨 Style/formatting changes
- [ ] 🧪 Test improvements
- [ ] 🔧 Configuration changes
## Test Plan
<!-- AI_INSTRUCTION: Provide specific testing instructions. Include both manual and automated testing steps. -->
### Manual Testing
- [Step 1: How to test this change]
- [Step 2: Expected behavior]
- [Step 3: Edge cases to verify]
## Breaking Changes
<!-- AI_INSTRUCTION: If this is a breaking change, provide detailed migration instructions. If no breaking changes, write "None" -->
[List any breaking changes and provide migration notes, or write "None" if not applicable]
## Checklist
<!-- AI_INSTRUCTION: Check ALL completed items. Ensure all items are addressed before marking as ready for review. -->
- [ ] 📝 Code follows the style guidelines
- [ ] 👀 Self-review has been performed
- [ ] 🧪 Tests have been added/updated
- [ ] 📖 Documentation has been updated
<!-- AI_TEMPLATE_END -->
IMPORTANT: Keep all section headings in English (e.g., "## Summary", "## Test Plan", "## Breaking Changes")
but write the content in the configured language include all required fields and checkboxes as appropriate.
### Step 3: Update PR
Save your description to a file and update the PR:
1. Save the description to description.md file
2. Update the PR: `gh pr edit --body-file description.md`
IMPORTANT: You must complete all 3 steps above. Do not stop after generating the description - execute the CLI commands to actually update the PR.
## Key Guidelines
- Write clear, concise descriptions
- Use proper markdown formatting
- Include all relevant technical details
- Consider both technical and non-technical readers
- IMPORTANT: Always use English section headings (e.g., "## Summary", "## Test Plan") but write content in the configured language
- MUST execute all CLI commands to complete the task - do not just provide instructions to the user
and keep generating follow output in CLI:
⬡ GitHub get_pull_request
⬡ GitHub get_pull_request_diff
⬢ Read packages/cli/src/ai/internal.ts
⬡ GitHub get_pull_request
⬡ GitHub get_pull_request_diff
⬢ Read packages/cli/src/ai/internal.ts
⬡ GitHub get_pull_request
⬡ GitHub get_pull_request_diff
⬡ Reading packages/cli/src/ai/internal.ts
Does this stop you from using Cursor
No - Cursor works, but with this issue