diff options
| author | Anthony Sottile <asottile@umich.edu> | 2019-12-03 17:45:45 +0000 |
|---|---|---|
| committer | Anthony Sottile <asottile@umich.edu> | 2019-12-03 17:45:45 +0000 |
| commit | 21d2adf21f86471d0bf56e6d444764aa3bb35884 (patch) | |
| tree | 18395a71ffe24a7f03dae269e611632d914b81ca /src/flake8 | |
| parent | 2ab681a4be8bc9a422080ad7f8c3a871292b90fa (diff) | |
| parent | 3b80b2e05a075e8de7149035643b2498e5a25c02 (diff) | |
| download | flake8-21d2adf21f86471d0bf56e6d444764aa3bb35884.tar.gz | |
Merge branch 'fix/disable_noqa' into 'master'
`--disable-noqa` does not override `# flake8: noqa`
Closes #590
See merge request pycqa/flake8!380
Diffstat (limited to 'src/flake8')
| -rw-r--r-- | src/flake8/processor.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/flake8/processor.py b/src/flake8/processor.py index ea8d3e2..0fd650b 100644 --- a/src/flake8/processor.py +++ b/src/flake8/processor.py @@ -346,7 +346,10 @@ class FileProcessor(object): :rtype: bool """ - if any(defaults.NOQA_FILE.match(line) for line in self.lines): + if ( + not self.options.disable_noqa + and any(defaults.NOQA_FILE.match(line) for line in self.lines) + ): return True elif any(defaults.NOQA_FILE.search(line) for line in self.lines): LOG.warning( |
