From c7b00227b7b7b04f2eafab6545c8c8515ef0adfc Mon Sep 17 00:00:00 2001 From: Egg Date: Wed, 9 Oct 2024 17:09:35 +0200 Subject: [PATCH] telegram: shorten polling --- active_bots/telegrambot.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/active_bots/telegrambot.py b/active_bots/telegrambot.py index 6e1573a..1b0e729 100644 --- a/active_bots/telegrambot.py +++ b/active_bots/telegrambot.py @@ -13,9 +13,9 @@ class TelegramBot(Bot): try: updates = tb.get_updates(offset=seen_tg + 1, allowed_updates="message", - timeout=5).wait() + timeout=1).wait() except TypeError: - updates = tb.get_updates(timeout=5).wait() + updates = tb.get_updates(timeout=1).wait() reports = [] if updates == None: return reports