Show More
@@ -609,14 +609,7 def has_root(): | |||
|
609 | 609 | |
|
610 | 610 | @check("pyflakes", "Pyflakes python linter") |
|
611 | 611 | def has_pyflakes(): |
|
612 | try: | |
|
613 | import pyflakes | |
|
614 | ||
|
615 | pyflakes.__version__ | |
|
616 | except ImportError: | |
|
617 | return False | |
|
618 | else: | |
|
619 | return True | |
|
612 | return matchoutput("pyflakes --version", br"^\d+\.\d+\.\d+\b", True) | |
|
620 | 613 | |
|
621 | 614 | |
|
622 | 615 | @check("pylint", "Pylint python linter") |
@@ -8,7 +8,7 run pyflakes on all tracked files ending | |||
|
8 | 8 | $ cat > test.py <<EOF |
|
9 | 9 | > print(undefinedname) |
|
10 | 10 | > EOF |
|
11 |
$ |
|
|
11 | $ pyflakes test.py 2>/dev/null | "$TESTDIR/filterpyflakes.py" | |
|
12 | 12 | test.py:1:* undefined name 'undefinedname' (glob) |
|
13 | 13 | |
|
14 | 14 | $ cd "`dirname "$TESTDIR"`" |
@@ -18,7 +18,7 run pyflakes on all tracked files ending | |||
|
18 | 18 | > -X contrib/python-zstandard \ |
|
19 | 19 | > -X mercurial/thirdparty \ |
|
20 | 20 | > 2>/dev/null \ |
|
21 |
> | xargs |
|
|
21 | > | xargs pyflakes 2>/dev/null | "$TESTDIR/filterpyflakes.py" | |
|
22 | 22 | contrib/perf.py:*:* undefined name 'xrange' (glob) (?) |
|
23 | 23 | mercurial/pycompat.py:*:* 'codecs' imported but unused (glob) |
|
24 | 24 | mercurial/pycompat.py:*:* 'concurrent.futures' imported but unused (glob) |
General Comments 0
You need to be logged in to leave comments.
Login now