diff options
author | Ryan Huber <rhuber@gmail.com> | 2015-07-23 14:10:56 -0700 |
---|---|---|
committer | Ryan Huber <rhuber@gmail.com> | 2015-07-23 14:10:56 -0700 |
commit | 48988c464e54bad25323487bc875f0f3d88b9b24 (patch) | |
tree | 55f2262a062b6dbf64475000309f1e0138535016 /wee_slack.py | |
parent | d9ac3383c1a7e59a35ba947c288d363f111aec2c (diff) | |
download | wee-slack-48988c464e54bad25323487bc875f0f3d88b9b24.tar.gz |
print the exception on a websocket connection failure
Diffstat (limited to 'wee_slack.py')
-rw-r--r-- | wee_slack.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/wee_slack.py b/wee_slack.py index b5210b9..a3d69c5 100644 --- a/wee_slack.py +++ b/wee_slack.py @@ -244,7 +244,8 @@ class SlackServer(object): self.ws_hook = w.hook_fd(self.ws.sock._sock.fileno(), 1, 0, 0, "slack_websocket_cb", self.identifier) self.ws.sock.setblocking(0) return True - except: + except Exception as e: + print("websocket connection error: {}".format(e)) return False def create_slack_mappings(self, data): |