1
0
mirror of https://github.com/eternnoir/pyTelegramBotAPI.git synced 2023-08-10 21:12:57 +03:00

Update README.md

This commit is contained in:
FrankWang 2015-07-15 13:09:24 +08:00
parent 1544efbbda
commit d5b7c2b49b

View File

@ -59,6 +59,10 @@ def listener(messages):
tb = telebot.TeleBot(TOKEN)
tb.set_update_listener(listener) #register listener
tb.polling()
# polling will not stop when get new message
tb.polling(True)
# Interval setup. Sleep 3 secs between request new message.
tb.polling(True, 3)
while True: # Don't let the main Thread end.
pass