개정판 553d54e4
issue #000: unhandled error msg added not only log file but also terminal box
Change-Id: Ia7ee273695f42e6e1b07c8706993339948c879b4
DTI_PID/DTI_PID/ExceptionHandler.py | ||
---|---|---|
28 | 28 |
|
29 | 29 |
def handler(self, exctype, value, traceback): |
30 | 30 |
""" log exception, file namd and line number """ |
31 |
from App import App |
|
32 |
from AppDocData import MessageType |
|
31 | 33 |
|
32 | 34 |
message = 'error occured({}) in {}:{}'.format(value, traceback.tb_frame.f_code.co_filename, traceback.tb_lineno) |
33 | 35 |
self.errorSignal.emit() |
34 |
self.logger.critical('Unhandled exception: {}'.format(message)) |
|
36 |
self.logger.critical('Unhandled exception: {}'.format(message)) |
|
37 |
|
|
38 |
App.mainWnd().addMessage.emit(MessageType.Error, message) |
내보내기 Unified diff