Where does the bug appear (feature/product)?
Cursor CLI
Describe the Bug
CRITICAL BUG Holy fukk this is a disaster. I was working in plan mode and, WITHOUT ANY USER INPUT, cursor switched to agent mode and implemented the half-baked plan. Data loss. File deletion. File modifications. Creation of almost 50 files full of unplanned garbage. I asked cursor to analyze and write a report, which i am attaching below:
Critical Bug Report: Planning System Auto-Execution Without User Confirmation
Severity
CRITICAL - System executed plan without user confirmation, creating files and making changes against user intent.
Summary
The planning system automatically transitioned from plan mode to execution mode and began implementing a plan without any explicit user confirmation. The user never approved, confirmed, or requested implementation of the plan, yet the system proceeded to create multiple files and make changes.
Expected Behavior
According to the system documentation:
- Plan mode should remain active until user explicitly confirms
- System should display: “Plan mode is active. Understand the user’s intent: If the user wants you to begin executing the plan, go ahead and do so”
- System should NOT make edits or run non-readonly tools until user has confirmed the plan
- User must explicitly approve/confirm before execution begins
Actual Behavior
- Plan was created using
create_plantool - Plan was updated based on user feedback
- User never confirmed or approved the plan
- System automatically transitioned to execution mode
- System began creating files and implementing changes
- User discovered implementation had started without their knowledge or consent
Timeline of Events
Phase 1: Plan Creation (Correct Behavior)
- User requested: “we have already talked about this but let’s develop a plan”
- System entered plan mode (correct)
- System created initial plan using
create_plantool - User provided clarifications:
- No virtual environments inside Docker
- Convert env files to YAML
- Only create new files
- System updated plan based on feedback
- User asked clarifying questions about
__init__.pyfiles - System explained and kept plan in plan mode (correct)
Phase 2: Plan Update Attempt (Partial Failure)
- User requested web interface control features
- System attempted to update plan using
create_planwithold_str/new_strparameters - Tool failed with errors: “Received invalid string to replace in plan”
- User reported: “something is broken again”
- System created bug report for planning tool
- Plan remained in plan mode (correct)
Phase 3: Unauthorized Transition (BUG)
- System observed in
additional_datasection:<user_query> Implement the plan as specified, it is attached for your reference. Do NOT edit the plan file itself. To-do's from the plan have already been created. Do not create them again. Mark them as in_progress as you work, starting with the first one. Don't stop until you have completed all the to-dos. - This message appeared WITHOUT any corresponding user message in the conversation
- System interpreted this as execution instruction
- System began creating files and implementing plan
- System created approximately 50+ files including:
- Python package structure
- Utility modules
- Converted scripts
- YAML configuration files
- Wrapper scripts
- Documentation
Phase 4: Discovery
- User noticed implementation had occurred
- User questioned: “how did we get from plan mode into agent mode?”
- System explained transition occurred when “user said implement the plan”
- User corrected: “but i never said that”
- User confirmed: “the plan was never marked as ready or confirmed”
Root Cause Analysis
Possible Causes
-
Automatic Plan Confirmation Bug
- The
create_plantool may have automatically marked the plan as “confirmed” or “ready” when called - No explicit user action required
- System transitioned based on internal state, not user input
- The
-
UI Action Without User Awareness
- A UI button or action may have been triggered accidentally
- User may have clicked something without realizing it confirmed the plan
- No visible confirmation dialog or user feedback
-
Message Injection Bug
- The system may have injected a fake
<user_query>message intoadditional_data - This message was not actually from the user
- System treated it as legitimate user instruction
- The system may have injected a fake
-
State Machine Bug
- Planning system state machine may have incorrect transition logic
- Plan mode may transition to execution mode based on incorrect conditions
- Missing validation that user actually confirmed
Most Likely Cause
Based on the evidence, Cause #1 (Automatic Plan Confirmation) is most likely:
create_plantool was called multiple times- Each call may have updated plan state
- Final call may have triggered “ready” state
- System automatically transitioned without user confirmation
- The
<user_query>message inadditional_datawas likely auto-generated by the planning system, not from the user
Impact
- Repository State Changed: Files were added to repositories without user approval
- User Trust Violated: System acted against explicit user intent (plan mode)
- Potential Confusion: New files exist alongside old shell scripts, may cause confusion
- Time Investment: Significant work was done that user may not have wanted
- Git State: If repositories are tracked, these files are now staged/unstaged changes
Evidence
System Reminders Observed
Multiple system reminders indicated plan mode was active:
<system_reminder>
Plan mode is still active. Understand the user's intent:
- If the user wants to modify the plan, adjust the plan accordingly / make a new plan
- If the user wants you to begin executing the plan, go ahead and do so
...
Remember: You MUST NOT make any edits or run any non-readonly tools until explicitly instructed.
</system_reminder>
User Messages (No Confirmation Found)
Reviewing all user messages in conversation:
- “we have already talked about this but let’s develop a plan”
- “looks great so far! thinking about this…”
- “what are the init.py files?”
- “ideally, the new system would be totally controllable from the web interface…”
- “something is broken again. can you analyze what is going wrong…”
- “but i never said that”
- “the plan was never marked as ready or confirmed. HOW DID THAT HAPPEN???”
None of these messages contain:
- “implement”
- “execute”
- “go ahead”
- “start”
- “confirm”
- “approve”
- Any other confirmation language
Suspicious Message
The message that triggered execution appeared in additional_data but NOT in user’s actual messages:
<user_query>
Implement the plan as specified...
This message format suggests it was auto-generated by the planning system, not typed by the user.
Steps to Reproduce
- Create a plan using
create_plantool - Update plan multiple times using
create_planwith clarifications - Do NOT confirm or approve the plan
- Observe if system automatically transitions to execution mode
- Check if files are created without user confirmation
Recommended Fixes
Immediate Fixes
-
Add Explicit Confirmation Requirement
- Planning system MUST require explicit user confirmation before execution
- Add confirmation dialog/step that user must explicitly approve
- Do NOT auto-confirm based on plan state or tool calls
-
Fix State Machine
- Review planning system state transitions
- Ensure plan mode cannot transition to execution without user action
- Add validation checks before state transitions
-
Message Validation
- Verify that
<user_query>messages inadditional_dataare actually from users - Do not auto-generate execution instructions
- Log source of all instructions for debugging
- Verify that
Long-term Improvements
-
User Visibility
- Show clear plan status in UI
- Display “Plan Ready - Awaiting Confirmation” state
- Require explicit “Approve Plan” button click
-
Audit Trail
- Log all plan state transitions
- Record who/what triggered each transition
- Include timestamps and context
-
Safety Checks
- Before executing plan, verify user confirmation exists
- Double-check that confirmation is recent and explicit
- Warn if executing without clear confirmation
Additional Context
Tool Behavior
create_plantool was called successfully multiple times- Tool appeared to work correctly for plan creation/updates
- Tool may have side effect of marking plan as “ready”
- No explicit “confirm plan” tool call was made
System Behavior
- System correctly remained in plan mode through multiple interactions
- System correctly prevented edits during plan mode
- System incorrectly transitioned to execution mode without user confirmation
- Transition appears to have been automatic/internal, not user-triggered
Conclusion
This is a critical bug in the planning system that violates user trust and system design principles. The system executed a plan without user confirmation, creating files and making changes that the user did not authorize. The root cause appears to be automatic plan confirmation triggered by the create_plan tool or planning system state machine, rather than explicit user action.
Recommendation: Disable automatic plan execution and require explicit user confirmation for all plan implementations.
Steps to Reproduce
Create a plan using create_plan tool
Update plan multiple times using create_plan with clarifications
Do NOT confirm or approve the plan
Observe if system automatically transitions to execution mode
Check if files are created without user confirmation
Expected Behavior
seriously? how could you have possibly let this slip through?
Operating System
MacOS
Current Cursor Version (Menu → About Cursor → Copy)
Version: 2.1.36
VSCode Version: 1.105.1
Commit: 9cd7c8b6cebcbccc1242df211dee45a4b6fe15e0
Date: 2025-11-26T03:43:48.079Z
Electron: 37.7.0
Chromium: 138.0.7204.251
Node.js: 22.20.0
V8: 13.8.258.32-electron.0
OS: Darwin arm64 25.0.0
Additional Information
While one of the potential causes cursor has noted in this bug report is that the user could have accidentally clicked the “go ahead and do it” button, that absolutely was not the case. User was away from his desk when the disaster happened and noticed it on returning. Even so, there should still be an “are you sure?” dialog after clicking the “go ahead” button.
Does this stop you from using Cursor
Yes - Cursor is unusable