Fix crash formatting traceback

This commit is contained in:
Mike Naberezny 2024-04-12 11:14:09 -07:00
parent 2b837bbd4f
commit 85ed46fd68
1 changed files with 2 additions and 2 deletions

View File

@ -163,8 +163,8 @@ class Monitor(cmd.Cmd):
result = cmd.Cmd.onecmd(self, line)
except KeyboardInterrupt:
self._output("Interrupt")
except Exception as e:
error = ''.join(traceback.format_exception(e))
except Exception:
error = ''.join(traceback.format_exception(*sys.exc_info()))
self._output(error)
if not line.startswith("quit"):