From 64c46c81cbcc52e694d9ddefbc321a243e4347f8 Mon Sep 17 00:00:00 2001 From: justuser-31 Date: Thu, 5 Feb 2026 20:11:50 +0300 Subject: [PATCH] =?UTF-8?q?=D0=98=D1=81=D0=BF=D1=80=D0=B0=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D0=B8=D0=B5=20=D0=BA=D1=80=D0=B0=D1=88=D0=B0=20?= =?UTF-8?q?=D0=B1=D0=BE=D1=82=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- telegram_bot/sfs_bot.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/telegram_bot/sfs_bot.py b/telegram_bot/sfs_bot.py index a0ec519..e9ba11c 100644 --- a/telegram_bot/sfs_bot.py +++ b/telegram_bot/sfs_bot.py @@ -198,6 +198,13 @@ def handle_user_leave(message): ) +from time import sleep if __name__ == "__main__": - print("SFS Bot started...") - bot.polling(none_stop=True) + while True: + try: + print("SFS Bot started...") + bot.polling(none_stop=True) + except KeyboardInterrupt: + exit(0) + except: + sleep(0.5)