I have been using flake8 for linting but somehow it stopped showing me errors in the code in any of my workspaces (the squiggly underlines in the editor).
flake8
is installed in my conda environment.
Here is my settings.json
:
{
"python.linting.enabled": true,
"python.linting.lintOnSave": true,
"python.linting.flake8Enabled": true,
"python.linting.flake8Args": [
"--max-line-length=80",
"--docstring-convention=google",
"--verbose"
]
}
When I run flake8
from the console, it does show me the errors.
I am using VS Code version 1.72.2 on Windows, and I installed flake8 version 5.0.4. Any idea what could be wrong with it?
2
Answers
Open Command Palette and type in
Linter
. Select the optionPython: Select Linter
and it opens up all the available linters.In the drop down, select
Flake8
and if required install it.That should work now!
Just add to
settings.json
: