diff options
Diffstat (limited to 'src/flake8/defaults.py')
| -rw-r--r-- | src/flake8/defaults.py | 47 |
1 files changed, 17 insertions, 30 deletions
diff --git a/src/flake8/defaults.py b/src/flake8/defaults.py index 3ad959b..61f2571 100644 --- a/src/flake8/defaults.py +++ b/src/flake8/defaults.py @@ -2,39 +2,26 @@ import re EXCLUDE = ( - '.svn', - 'CVS', - '.bzr', - '.hg', - '.git', - '__pycache__', - '.tox', - '.eggs', - '*.egg', + ".svn", + "CVS", + ".bzr", + ".hg", + ".git", + "__pycache__", + ".tox", + ".eggs", + "*.egg", ) -IGNORE = ( - 'E121', - 'E123', - 'E126', - 'E226', - 'E24', - 'E704', - 'W503', - 'W504', -) -SELECT = ('E', 'F', 'W', 'C90') +IGNORE = ("E121", "E123", "E126", "E226", "E24", "E704", "W503", "W504") +SELECT = ("E", "F", "W", "C90") MAX_LINE_LENGTH = 79 -TRUTHY_VALUES = {'true', '1', 't'} +TRUTHY_VALUES = {"true", "1", "t"} # Other constants -WHITESPACE = frozenset(' \t') +WHITESPACE = frozenset(" \t") -STATISTIC_NAMES = ( - 'logical lines', - 'physical lines', - 'tokens', -) +STATISTIC_NAMES = ("logical lines", "physical lines", "tokens") NOQA_INLINE_REGEXP = re.compile( # We're looking for items that look like this: @@ -46,8 +33,8 @@ NOQA_INLINE_REGEXP = re.compile( # We do not care about the ``: `` that follows ``noqa`` # We do not care about the casing of ``noqa`` # We want a comma-separated list of errors - r'# noqa(?:: (?P<codes>([A-Z][0-9]+(?:[,\s]+)?)+))?', - re.IGNORECASE + r"# noqa(?:: (?P<codes>([A-Z][0-9]+(?:[,\s]+)?)+))?", + re.IGNORECASE, ) -NOQA_FILE = re.compile(r'\s*# flake8[:=]\s*noqa', re.I) +NOQA_FILE = re.compile(r"\s*# flake8[:=]\s*noqa", re.I) |
