From 5ebae02bf2d413bb8f15db6d1a77768b746300d4 Mon Sep 17 00:00:00 2001 From: Mark Veidemanis Date: Wed, 21 Sep 2022 10:02:05 +0100 Subject: [PATCH] Remove commented code for debugging --- db.py | 12 ++++++------ monolith.py | 12 ++++++------ sources/ingest.py | 4 ++-- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/db.py b/db.py index 1f52c48..37aff5c 100644 --- a/db.py +++ b/db.py @@ -62,12 +62,12 @@ async def store_kafka_batch(data): KAFKA_TOPIC = index - # if key in schema: - # if isinstance(value, int): - # if schema[key].startswith("string") or schema[key].startswith( - # "text" - # ): - # msg[key] = str(value) + # if key in schema: + # if isinstance(value, int): + # if schema[key].startswith("string") or schema[key].startswith( + # "text" + # ): + # msg[key] = str(value) body = orjson.dumps(msg) if "ts" not in msg: raise Exception("No TS in msg") diff --git a/monolith.py b/monolith.py index 5caebf8..1eb559b 100644 --- a/monolith.py +++ b/monolith.py @@ -16,13 +16,13 @@ if not token: async def main(loop): - # log.info("Starting Discord handler.") - # client = DiscordClient() - # loop.create_task(client.start(token)) + log.info("Starting Discord handler.") + client = DiscordClient() + loop.create_task(client.start(token)) - # log.info("Starting 4chan handler.") - # chan = Chan4() - # loop.create_task(chan.run()) + log.info("Starting 4chan handler.") + chan = Chan4() + loop.create_task(chan.run()) log.info("Starting ingest handler.") ingest = Ingest() diff --git a/sources/ingest.py b/sources/ingest.py index 4edb496..21418b4 100644 --- a/sources/ingest.py +++ b/sources/ingest.py @@ -9,8 +9,8 @@ from processing import process SOURCES = ["4ch", "irc", "dis"] # DEBUG CODE REMOVE ME -SOURCES.remove("4ch") -SOURCES.remove("dis") +# SOURCES.remove("4ch") +# SOURCES.remove("dis") # DEBUG CODE REMOVE ME KEYPREFIX = "queue."