From d0be259f354f4ecc1e7e67fa5004fc103095eb96 Mon Sep 17 00:00:00 2001 From: Stefano Pigozzi Date: Tue, 14 Mar 2017 14:10:12 +0100 Subject: [PATCH] Improved the reply time Maybe. --- telegram.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/telegram.py b/telegram.py index 0199bfea..2bb50585 100644 --- a/telegram.py +++ b/telegram.py @@ -40,6 +40,8 @@ class Bot: for u in self.updates: loop.create_task(self.parse_update(u)) self.updates = list() + # Wait 1 second between two requests, allowing the parsing of updates. + loop.run_until_complete(asyncio.sleep(1)) async def update_bot_data(self): """Update self.user_data with the latest information from /getMe."""