Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
populate_db: Remove unused `output`.
PIG208434b7e360a8b
diff --git a/zilencer/management/commands/populate_db.py b/zilencer/management/commands/populate_db.pyindex f0e14544e64..9c6c13b9366 100644--- a/zilencer/management/commands/populate_db.py+++ b/zilencer/management/commands/populate_db.py@@ -3,7 +3,7 @@ import osimport randomfrom collections import defaultdictfrom datetime import datetime-from typing import Any, Callable, Dict, List, Mapping, Sequence, Tuple+from typing import Any, Dict, List, Mapping, Sequence, Tupleimport bmemcachedimport orjson@@ -870,14 +870,12 @@ class Command(BaseCommand):call_command("populate_analytics_db")threads = options["threads"]- jobs: List[Tuple[int, List[List[int]], Dict[str, Any], Callable[[str], int], int]] = []+ jobs: List[Tuple[int, List[List[int]], Dict[str, Any], int]] = []for i in range(threads):count = options["num_messages"] // threadsif i < options["num_messages"] % threads:count += 1- jobs.append(- (count, personals_pairs, options, self.stdout.write, random.randint(0, 10 ** 10))- )+ jobs.append((count, personals_pairs, options, random.randint(0, 10 ** 10)))for job in jobs:generate_and_send_messages(job)@@ -935,9 +933,9 @@ def get_recipient_by_id(rid: int) -> Recipient:# - multiple messages per subject# - both single and multi-line contentdef generate_and_send_messages(- data: Tuple[int, Sequence[Sequence[int]], Mapping[str, Any], Callable[[str], Any], int]+ data: Tuple[int, Sequence[Sequence[int]], Mapping[str, Any], int]) -> int:- (tot_messages, personals_pairs, options, output, random_seed) = data+ (tot_messages, personals_pairs, options, random_seed) = datarandom.seed(random_seed)with open(