Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

runtornado: Fix COM818 Trailing comma on bare tuple prohibited.

Anders Kaseorgff409342e156
diff --git a/pyproject.toml b/pyproject.toml
index 95f7be1c220..f279365faa7 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -96,6 +96,7 @@ select = [
"ANN", # annotations
"B", # bugbear
"C4", # comprehensions
+ "COM", # trailing comma
"DJ", # Django
"DTZ", # naive datetime
"E", # style errors
@@ -129,6 +130,7 @@ ignore = [
"B023", # Function definition does not bind loop variable
"B904", # Within an except clause, raise exceptions with raise ... from err or raise ... from None to distinguish them from errors in exception handling
"C408", # Unnecessary `dict` call (rewrite as a literal)
+ "COM812", # Trailing comma missing
"DJ001", # Avoid using `null=True` on string-based fields
"DJ008", # Model does not define `__str__` method
"E402", # Module level import not at top of file
diff --git a/zerver/management/commands/runtornado.py b/zerver/management/commands/runtornado.py
index e74ea0d9698..51457414e8a 100644
--- a/zerver/management/commands/runtornado.py
+++ b/zerver/management/commands/runtornado.py
@@ -79,12 +79,12 @@ class Command(BaseCommand):
stop_fut.set_result(None)
def add_signal_handlers() -> None:
- loop.add_signal_handler(signal.SIGINT, stop),
- loop.add_signal_handler(signal.SIGTERM, stop),
+ loop.add_signal_handler(signal.SIGINT, stop)
+ loop.add_signal_handler(signal.SIGTERM, stop)
def remove_signal_handlers() -> None:
- loop.remove_signal_handler(signal.SIGINT),
- loop.remove_signal_handler(signal.SIGTERM),
+ loop.remove_signal_handler(signal.SIGINT)
+ loop.remove_signal_handler(signal.SIGTERM)
async with AsyncExitStack() as stack:
stack.push_async_callback(