Commit 51645b6e authored by eric pellegrini's avatar eric pellegrini

redirected the sys.stdout and sys.stderr to the LOGGER

parent c990b09b
......@@ -91,12 +91,17 @@ class MainFrame(wx.Frame):
self.build_dialog()
# Add some handlers to the loggers
LOGGER.add_handler("console", REGISTRY['handler']['console'](self._panels["controller"].pages["logger"]), level="info")
consoleHandler = REGISTRY['handler']['console'](self._panels["controller"].pages["logger"])
LOGGER.add_handler("console", consoleHandler, level="info")
LOGGER.add_handler("dialog", REGISTRY['handler']['dialog'](), level="error")
LOGGER.start()
# Redirect all output to the console logger
sys.stdout = consoleHandler
sys.stderr = consoleHandler
sys.excepthook = excepthook
def build_dialog(self):
self.build_menu()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment