From 69279108bcf90eddd836dbdeef9aeae166cfec5b Mon Sep 17 00:00:00 2001 From: Taneli Hukkinen Date: Mon, 4 Nov 2019 21:16:09 +0100 Subject: [PATCH] Add flake8-bugbear --- setup.py | 1 + tests_interop/daemon.py | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/setup.py b/setup.py index f9c2668..30c820e 100644 --- a/setup.py +++ b/setup.py @@ -15,6 +15,7 @@ extras_require = { "black==19.3b0", "isort==4.3.21", "flake8>=3.7.7,<4.0.0", + "flake8-bugbear", ], "dev": ["tox>=3.13.2,<4.0.0", "docformatter"], } diff --git a/tests_interop/daemon.py b/tests_interop/daemon.py index 83aa82d..a1b60fa 100644 --- a/tests_interop/daemon.py +++ b/tests_interop/daemon.py @@ -32,7 +32,9 @@ async def try_until_success(coro_func, timeout=TIMEOUT_DURATION): break if (time.monotonic() - t_start) >= timeout: # timeout - assert False, f"{coro_func} is still failing after `{timeout}` seconds" + raise AssertionError( + f"{coro_func} is still failing after `{timeout}` seconds" + ) await asyncio.sleep(0.01)