Revert "Minor adjustments for Tornado 5"

This reverts commit 258f3725bf.
This commit is contained in:
Gina Häußge committed 2018-04-20 22:39:25 +02:00
1 parent 555bdefd46
commit d3e7842c3a
2 files changed
+3 -5

No files matched your search

+2 -4
View File
@@ -490,7 +490,7 @@ class Server(object):
## Tornado initialization starts here
ioloop = IOLoop()
ioloop.make_current()
ioloop.install()
self._router = SockJSRouter(self._create_socket_connection, "/sockjs",
session_kls=util.sockjs.ThreadSafeSession)
@@ -760,9 +760,7 @@ class Server(object):
except (KeyboardInterrupt, SystemExit):
pass
except:
self._logger.fatal("Now that is embarrassing... Something really really went wrong here. Please report "
"this including reproduction steps, octoprint.log and the stacktrace below in "
"OctoPrint's bugtracker. Thanks!")
self._logger.fatal("Now that is embarrassing... Something really really went wrong here. Please report this including the stacktrace below in OctoPrint's bugtracker. Thanks!")
self._logger.exception("Stacktrace follows:")
def _create_socket_connection(self, session):
+1 -1
View File
@@ -91,7 +91,7 @@ class SockJSRouter(object):
self._connection = connection
# Initialize io_loop
self.io_loop = io_loop or ioloop.IOLoop.current()
self.io_loop = io_loop or ioloop.IOLoop.instance()
# Settings
self.settings = DEFAULT_SETTINGS.copy()