diff options
author | Jesse Luehrs <doy@tozt.net> | 2014-10-16 13:20:11 -0400 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2014-10-16 13:20:11 -0400 |
commit | c3f0dd84b4937f2dea495733b1006a3862fd970e (patch) | |
tree | 76c7b7378a542c5d66568902e2ebd86b7850cb8c | |
parent | 89a35eb5d0806006d2e9f42c4a2358d7fd12e606 (diff) | |
download | python-termcast-server-c3f0dd84b4937f2dea495733b1006a3862fd970e.tar.gz python-termcast-server-c3f0dd84b4937f2dea495733b1006a3862fd970e.zip |
and make absolutely sure we handle everything
-rw-r--r-- | termcast_server/__init__.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/termcast_server/__init__.py b/termcast_server/__init__.py index 47d7ba6..ca6adc0 100644 --- a/termcast_server/__init__.py +++ b/termcast_server/__init__.py @@ -78,7 +78,10 @@ class Server(object): connection_id = uuid.uuid4().hex connection = cb(client, connection_id) self.publisher.subscribe(connection) - connection.run() + try: + connection.run() + except Exception as e: + print('Running connection failed: ' + str(e)) self.publisher.unsubscribe(connection) client.close() |