From 1cdebc50ba97f3b8eef1df509ed381f3836cba78 Mon Sep 17 00:00:00 2001 From: carlio Date: Sat, 31 Jan 2015 10:09:09 +0100 Subject: [PATCH] [refs #100] The pyflakes tool should still understand old codes --- prospector/tools/pyflakes/__init__.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/prospector/tools/pyflakes/__init__.py b/prospector/tools/pyflakes/__init__.py index 21f59a7e..5f951576 100644 --- a/prospector/tools/pyflakes/__init__.py +++ b/prospector/tools/pyflakes/__init__.py @@ -120,7 +120,9 @@ def __init__(self, *args, **kwargs): self.ignore_codes = () def configure(self, prospector_config, _): - self.ignore_codes = prospector_config.get_disabled_messages('pyflakes') + ignores = prospector_config.get_disabled_messages('pyflakes') + # convert old style to new + self.ignore_codes = (LEGACY_CODE_MAP.get(code, code) for code in ignores) return None def run(self, found_files):