I'm getting these TabErrors constantly and it's really slowing down my work flow. I can't figure out how to make them go away. I get them to disappear by completely retyping my script, and then I add a new function and suddenly everything is messed up again. I have not changed the way I indent my code. I am not adding extra whitespace. I am not doing anything differently but suddenly I'm getting TabErrors all the time. I'm using vscode. Is there something I can use to properly format my code? I really need this problem to stop happening.
CodePudding user response:
Add this to your settings.json
file
"[python]": {
"editor.insertSpaces": true, // if you want to use spaces, false for tabs
"editor.tabSize": 4,
} // you may need a trailing comma here - you've been warned!