pycodestyle entry point means "noqa" is not populated
ipolding-cais opened this issue · comments
ipolding-cais commented
how did you install flake8?
$ pip install flake8
unmodified output of flake8 --bug-report
{
"platform": {
"python_implementation": "CPython",
"python_version": "3.10.13",
"system": "Darwin"
},
"plugins": [
{
"plugin": "mccabe",
"version": "0.7.0"
},
{
"plugin": "pycodestyle",
"version": "2.11.1"
},
{
"plugin": "pyflakes",
"version": "3.2.0"
}
],
"version": "7.0.0"
}
describe the problem
what I expected to happen
Flake8 should give the same output as pycodestyle when selecting E501 but pycodestyle's noqa
argument is set to false in flake8
Here is the noqa
attribute that should be populated: https://github.com/PyCQA/pycodestyle/blob/main/pycodestyle.py#L1721
...
sample code
print("this line has 65 characters plus an example noqa comment")# noqa: B018
commands ran
$ pycodestyle --max-line-length 65 --select E501 code_sample.py # no errors; noqa comment is ignored
$ flake8 --max-line-length 65 --select E501 code_sample.py # E501 error; noqa comment is included as part of line
Anthony Sottile commented
pycodestyle's interpretation of noqa does not include codes and is intentionally different from the improvements made in flake8