[Bug] Inconsistent Python Code Indentation in Generated Output
Resolved 💬 3 comments Opened Oct 1, 2025 by josephphanpplx Closed Jan 6, 2026
Bug Description
When you ask Claude Code for Python code, you have to copy and paste it into a text editor and fix all the indentation before you can run it because everything from the 2nd line on is indented 2 spaces, and then everything else is indented by 4 spaces for every level of nesting, so I have to do a search and replace to change all those 4 spaces to 2 spaces.
Screenshot
Environment Info
- Platform: darwin
- Terminal: iTerm.app
- Version: 2.0.2
- Feedback ID:
Errors
[{"error":"Error: Cannot submit feedback because custom data retention settings are enabled\n at QI6 (file:///Users/josephphan/.nvm/versions/node/v22.18.0/lib/node_modules/@anthropic-ai/claude-code/cli.js:1371:1046)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n at async Promise.all (index 0)\n at async file:///Users/josephphan/.nvm/versions/node/v22.18.0/lib/node_modules/@anthropic-ai/claude-code/cli.js:1357:12885","timestamp":"2025-10-01T14:31:19.776Z"}]This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗