From 5e08b4a5013e844efc617aa686ff9d6c00d89ef3 Mon Sep 17 00:00:00 2001 From: Frisk Date: Mon, 8 Mar 2021 19:00:12 +0100 Subject: [PATCH] Start ignoring the additional delay for wikis with IRC feed. We have IRC feed only for more active domains so this additional delay does more bad than good --- src/bot.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/bot.py b/src/bot.py index c3fc1bb..c43ef57 100644 --- a/src/bot.py +++ b/src/bot.py @@ -249,7 +249,8 @@ async def scan_group(group: str): while True: try: async with rcqueue.retrieve_next_queued(group) as queued_wiki: # acquire next wiki in queue - await asyncio.sleep(calculate_delay_for_group(len(rcqueue[group]["query"]))) + if "irc" not in rcqueue[group]: + await asyncio.sleep(calculate_delay_for_group(len(rcqueue[group]["query"]))) logger.debug("Wiki {}".format(queued_wiki.url)) local_wiki = all_wikis[queued_wiki.url] # set a reference to a wiki object from memory extended = False @@ -346,7 +347,7 @@ async def scan_group(group: str): except asyncio.CancelledError: return except QueueEmpty: - await asyncio.sleep(21.0) + await asyncio.sleep(10.0) continue