Bug Report for Cursor Team
Issue Description
There appears to be a significant issue with Cursor’s AI code editing functionality when attempting to make changes to Markdown files containing code blocks.
Bug Details
- Issue Type: Markdown editing/application failure
- Frequency: Consistent (multiple failed attempts)
- Files Affected: README.md
Reproduction Steps
- Ask Cursor AI to add or modify a code block section in a Markdown file
- AI attempts to provide a fix that includes modifications to existing code blocks
- When trying to apply the changes, they fail to be properly implemented
- Multiple simple approaches also fail to apply correctly
Specific Symptoms
- Complex formatting like ASCII diagrams completely fails to apply
- Simple text additions around code blocks often fails
- Nested code blocks in markdown seem particularly problematic
- Even when using simplified suggestions, changes don’t apply correctly
Impact
This bug significantly impacts productivity when working with documentation:
- Requires multiple attempts to make simple changes
- Forces users to manually implement changes instead of using the AI assistant
- Creates a frustrating user experience and breaks the flow of development
Technical Context
The issue appears related to how the application model processes markdown with code blocks. Even when AI suggestions follow proper markdown syntax, the apply model seems unable to correctly parse the structure of markdown files that contain code blocks.
Suggested Investigation
- Review how the apply model handles nested code blocks in markdown
- Investigate the parsing of triple backtick code fences in markdown files
- Consider adding better error reporting when changes fail to apply
User Environment
- Using Cursor with Claude 3.7 Sonnet model
- Working with Rust/Godot project documentation
- Markdown file contains multiple nested code blocks
This is a serious usability issue that prevents proper use of the AI assistant for documentation tasks.