|
|
|
@ -78,14 +78,14 @@ class IndexHandler(MixinHandler, tornado.web.RequestHandler):
|
|
|
|
|
if not swallow_http_errors: |
|
|
|
|
super(MixinHandler, self).write_error(status_code, **kwargs) |
|
|
|
|
else: |
|
|
|
|
if status_code == 500: |
|
|
|
|
self._reason = 'Internal Server Error' |
|
|
|
|
else: |
|
|
|
|
exc_info = kwargs.get('exc_info') |
|
|
|
|
if exc_info: |
|
|
|
|
self._reason = exc_info[1].log_message |
|
|
|
|
exc_info = kwargs.get('exc_info') |
|
|
|
|
if exc_info: |
|
|
|
|
reason = getattr(exc_info[1], 'log_message', None) |
|
|
|
|
if reason: |
|
|
|
|
self._reason = reason |
|
|
|
|
self.result.update(status=self._reason) |
|
|
|
|
self.set_status(200) |
|
|
|
|
self.set_header('Server', 'TornadoServer') |
|
|
|
|
self.finish(self.result) |
|
|
|
|
|
|
|
|
|
def get_ssh_client(self): |
|
|
|
|