init
This commit is contained in:
commit
38355d2442
9083 changed files with 1225834 additions and 0 deletions
44
.venv/lib/python3.8/site-packages/flake8/defaults.py
Normal file
44
.venv/lib/python3.8/site-packages/flake8/defaults.py
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
"""Constants that define defaults."""
|
||||
import re
|
||||
|
||||
EXCLUDE = (
|
||||
".svn",
|
||||
"CVS",
|
||||
".bzr",
|
||||
".hg",
|
||||
".git",
|
||||
"__pycache__",
|
||||
".tox",
|
||||
".eggs",
|
||||
"*.egg",
|
||||
)
|
||||
IGNORE = ("E121", "E123", "E126", "E226", "E24", "E704", "W503", "W504")
|
||||
SELECT = ("E", "F", "W", "C90")
|
||||
MAX_LINE_LENGTH = 79
|
||||
INDENT_SIZE = 4
|
||||
|
||||
TRUTHY_VALUES = {"true", "1", "t"}
|
||||
|
||||
# Other constants
|
||||
WHITESPACE = frozenset(" \t")
|
||||
|
||||
STATISTIC_NAMES = ("logical lines", "physical lines", "tokens")
|
||||
|
||||
NOQA_INLINE_REGEXP = re.compile(
|
||||
# We're looking for items that look like this:
|
||||
# ``# noqa``
|
||||
# ``# noqa: E123``
|
||||
# ``# noqa: E123,W451,F921``
|
||||
# ``# noqa:E123,W451,F921``
|
||||
# ``# NoQA: E123,W451,F921``
|
||||
# ``# NOQA: E123,W451,F921``
|
||||
# ``# NOQA:E123,W451,F921``
|
||||
# We do not want to capture the ``: `` that follows ``noqa``
|
||||
# We do not care about the casing of ``noqa``
|
||||
# We want a comma-separated list of errors
|
||||
# https://regex101.com/r/4XUuax/2 full explanation of the regex
|
||||
r"# noqa(?::[\s]?(?P<codes>([A-Z]+[0-9]+(?:[,\s]+)?)+))?",
|
||||
re.IGNORECASE,
|
||||
)
|
||||
|
||||
NOQA_FILE = re.compile(r"\s*# flake8[:=]\s*noqa", re.I)
|
||||
Loading…
Add table
Add a link
Reference in a new issue