diff options
| author | Anthony Sottile <asottile@umich.edu> | 2019-01-19 11:59:38 -0800 |
|---|---|---|
| committer | Anthony Sottile <asottile@umich.edu> | 2019-01-19 12:02:44 -0800 |
| commit | 03ea38df168036a38aff7af916c07c05fe1f2eb2 (patch) | |
| tree | dbe54077131d857b5e462e93eaa16962be3aae02 /src | |
| parent | 0f3f4ff9b4e7901695484ee1ea1fbcbc19632149 (diff) | |
| download | flake8-03ea38df168036a38aff7af916c07c05fe1f2eb2.tar.gz | |
WIP: use latest pyflakes
Diffstat (limited to 'src')
| -rw-r--r-- | src/flake8/plugins/pyflakes.py | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/flake8/plugins/pyflakes.py b/src/flake8/plugins/pyflakes.py index 880373a..4435380 100644 --- a/src/flake8/plugins/pyflakes.py +++ b/src/flake8/plugins/pyflakes.py @@ -30,6 +30,8 @@ FLAKE8_PYFLAKES_CODES = { "TooManyExpressionsInStarredAssignment": "F621", "TwoStarredExpressions": "F622", "AssertTuple": "F631", + "IsLiteral": "F632", + "InvalidPrintSyntax": "F633", "BreakOutsideLoop": "F701", "ContinueOutsideLoop": "F702", "ContinueInFinally": "F703", @@ -39,6 +41,7 @@ FLAKE8_PYFLAKES_CODES = { "DefaultExceptNotLast": "F707", "DoctestSyntaxError": "F721", "ForwardAnnotationSyntaxError": "F722", + "CommentAnnotationSyntaxError": "F723", "RedefinedWhileUnused": "F811", "RedefinedInListComp": "F812", "UndefinedName": "F821", @@ -72,7 +75,7 @@ class FlakesChecker(pyflakes.checker.Checker): include_in_doctest = [] exclude_from_doctest = [] - def __init__(self, tree, filename): + def __init__(self, tree, file_tokens, filename): """Initialize the PyFlakes plugin with an AST tree and filename.""" filename = utils.normalize_paths(filename)[0] with_doctest = self.with_doctest @@ -97,7 +100,10 @@ class FlakesChecker(pyflakes.checker.Checker): with_doctest = True super(FlakesChecker, self).__init__( - tree, filename=filename, withDoctest=with_doctest + tree, + filename=filename, + withDoctest=with_doctest, + file_tokens=file_tokens, ) @classmethod |
