Answer the question
In order to leave comments, you need to log in
How to make a mailing list in Telegram [Python]?
There is a bot in the telegram, there is also a database in which the user ids of the bot are located. The bot
is written on the PyTelegramBotApi module.
Please tell me how to bypass users who have blocked the bot (because of them, the bot crashes when sending)
Answer the question
In order to leave comments, you need to log in
You need to use the try except construct:
for user in user_ids:
try:
send_message()#Отправляешь сообщение, как там это делается
except:
pass #Тут что делать в противном случае
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question