Try to handle better exceptions in the chat server

This commit is contained in:
Manuel Cortez 2018-12-20 16:58:29 -06:00
parent ca3873f055
commit 93e6cd36a7

View File

@ -23,5 +23,5 @@ class worker(threading.Thread):
pub.sendMessage("user-online", event=event) pub.sendMessage("user-online", event=event)
elif event.type == VkEventType.USER_OFFLINE: elif event.type == VkEventType.USER_OFFLINE:
pub.sendMessage("user-offline", event=event) pub.sendMessage("user-offline", event=event)
except ReadTimeout, ConnectionError: except:
pub.sendMessage("longpoll-read-timeout") pub.sendMessage("longpoll-read-timeout")