Answer the question
In order to leave comments, you need to log in
How to reload bot on pyTelegramBotAPI?
Hello, I am writing a bot on pyTelegramBotAPI. I would like to restart the bot when an error is caught.
The code:
except OverridingEx: #Ловлю ошибку
bot.send_message(message.chat.id, 'Ошибка, обратитесь к создателю (@moodguy), чтобы он перезагрузил бота.') #здесь нужно сделать перезагрузку
Answer the question
In order to leave comments, you need to log in
Drive all the code into a try except construct, which will be True in while
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question