summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Reiter <reiter.christoph@gmail.com>2020-05-17 23:01:11 +0200
committerChristoph Reiter <reiter.christoph@gmail.com>2020-05-30 19:58:52 +0200
commit8cfc13a0135ec0fc13ca333e5bf6858740e11d8b (patch)
treef3015962ef0b208bda5d51f7f0cc91e15dd6d400
parent3a3aa3baf4654bc3a939553a584e65b012293c6f (diff)
downloadpygobject-3-34.tar.gz
flake8: fix errors with new flake8 3.8.0pygobject-3-34
-rw-r--r--examples/demo/demos/printing.py4
-rw-r--r--tests/test_gobject.py8
2 files changed, 6 insertions, 6 deletions
diff --git a/examples/demo/demos/printing.py b/examples/demo/demos/printing.py
index 6e68037d..a87bd6fd 100644
--- a/examples/demo/demos/printing.py
+++ b/examples/demo/demos/printing.py
@@ -92,8 +92,8 @@ class PrintingApp:
file_path = print_data['filename']
if not os.path.isfile(file_path):
file_path = os.path.join('demos', file_path)
- if not os.path.isfile:
- raise Exception("file not found: " % (file_path, ))
+ if not os.path.isfile(file_path):
+ raise Exception("file not found: %s" % (file_path, ))
# in reality you should most likely not read the entire
# file into a buffer
diff --git a/tests/test_gobject.py b/tests/test_gobject.py
index bba12cb7..1e557de7 100644
--- a/tests/test_gobject.py
+++ b/tests/test_gobject.py
@@ -804,8 +804,8 @@ class TestGValue(unittest.TestCase):
def test_list_properties():
- def find_param(l, name):
- for param in l:
+ def find_param(props, name):
+ for param in props:
if param.name == name:
return param
return
@@ -822,8 +822,8 @@ def test_list_properties():
props = list_props(Gio.SimpleAction)
assert find_param(props, "enabled")
- def names(l):
- return [p.name for p in l]
+ def names(props):
+ return [p.name for p in props]
assert (set(names(list_props(Gio.Action))) <=
set(names(list_props(Gio.SimpleAction))))