diff options
author | Hugo van Kemenade <hugovk@users.noreply.github.com> | 2021-05-03 01:40:05 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-02 15:40:05 -0700 |
commit | df79a6390f6d0531f6411f745d0ccd2c3d674883 (patch) | |
tree | 182575a9f279d791c9a3f724ed8373c750cb49bd /lab/parse_all.py | |
parent | bb73791b59f74b6621a87036c14a6be6a23e0e55 (diff) | |
download | python-coveragepy-git-df79a6390f6d0531f6411f745d0ccd2c3d674883.tar.gz |
refactor: remove redundant Python 2 code (#1155)
* Remove Python 2 code
* Upgrade Python syntax with pyupgrade
* Upgrade Python syntax with pyupgrade --py3-plus
* Upgrade Python syntax with pyupgrade --py36-plus
* Remove unused imports
Diffstat (limited to 'lab/parse_all.py')
-rw-r--r-- | lab/parse_all.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lab/parse_all.py b/lab/parse_all.py index b14c1f0e..3b2465d9 100644 --- a/lab/parse_all.py +++ b/lab/parse_all.py @@ -3,17 +3,16 @@ import os import sys -from coverage.exceptions import CoverageException from coverage.parser import PythonParser for root, dirnames, filenames in os.walk(sys.argv[1]): for filename in filenames: if filename.endswith(".py"): filename = os.path.join(root, filename) - print(":: {}".format(filename)) + print(f":: {filename}") try: par = PythonParser(filename=filename) par.parse_source() par.arcs() except Exception as exc: - print(" ** {}".format(exc)) + print(f" ** {exc}") |