Skip to content

Commit 874f093

Browse files
Normalize noqa directives
warning: Invalid rule code provided to `# noqa`
1 parent 0e7da2c commit 874f093

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

distributed/cfexecutor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ def _cascade_future(future, cf_future):
3030
try:
3131
typ, exc, tb = result
3232
raise exc.with_traceback(tb)
33-
except BaseException as exc: # noqa: B036
33+
except BaseException as exc:
3434
cf_future.set_exception(exc)
3535

3636

distributed/tests/test_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6390,7 +6390,7 @@ async def test_profile_server_disabled(c, s, a, b):
63906390
async def test_await_future(c, s, a, b):
63916391
future = c.submit(inc, 1)
63926392

6393-
async def f(): # flake8: noqa
6393+
async def f():
63946394
result = await future
63956395
assert result == 2
63966396

distributed/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -468,7 +468,7 @@ def __init__(self, target: Callable[[], None], daemon: bool, name: str):
468468
def wrapper() -> None:
469469
try:
470470
target()
471-
except BaseException as e: # noqa: B036
471+
except BaseException as e:
472472
self._exception = e
473473

474474
self._thread = thread = threading.Thread(

distributed/worker.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2994,7 +2994,7 @@ def _run_task_simple(
29942994
# Any other `BaseException` types would ultimately be ignored by asyncio if
29952995
# raised here, after messing up the worker state machine along their way.
29962996
raise
2997-
except BaseException as e: # noqa: B036
2997+
except BaseException as e:
29982998
# Users _shouldn't_ use `BaseException`s, but if they do, we can assume they
29992999
# aren't a reason to shut down the whole system (since we allow the
30003000
# system-shutting-down `SystemExit` and `KeyboardInterrupt` to pass through)
@@ -3038,7 +3038,7 @@ async def _run_task_async(
30383038
# Any other `BaseException` types would ultimately be ignored by asyncio if
30393039
# raised here, after messing up the worker state machine along their way.
30403040
raise
3041-
except BaseException as e: # noqa: B036
3041+
except BaseException as e:
30423042
# NOTE: this includes `CancelledError`! Since it's a user task, that's _not_
30433043
# a reason to shut down the worker.
30443044
# Users _shouldn't_ use `BaseException`s, but if they do, we can assume they

0 commit comments

Comments
 (0)