[Bug] File editing fails due to indentation mismatch between Read tool output and actual file content
Resolved 💬 2 comments Opened Oct 25, 2025 by dbarnett Closed Oct 26, 2025
Bug Description
Claude is repeatedly failing to edit files to the point that it's absolutely embarrassing. It seems to be something about misunderstanding the indentation and tabs vs spaces but even after repeatedly using sed to check indentation it's sometimes taking 5 attempts to successfully apply an edit. Apparently sometimes the Read tool is returning spaces on context lines when the actual file has tabs and it's getting completely stuck on that.
Environment Info
- Platform: linux
- Terminal: vscode
- Version: 2.0.27
- Feedback ID: fba6358a-c8fb-4e2d-bc7c-d1b82218db1f
Errors
[]This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗