mirror of
https://github.com/kevingruesser/bootstrap-vz.git
synced 2025-10-07 17:40:30 +00:00
Serialize exception info by printing it
This commit is contained in:
parent
150b15bb4f
commit
922cabe80a
1 changed files with 4 additions and 0 deletions
|
@ -13,6 +13,10 @@ class LogForwarder(logging.Handler):
|
|||
|
||||
def emit(self, record):
|
||||
if self.server is not None:
|
||||
if record.exc_info is not None:
|
||||
import traceback
|
||||
exc_type, exc_value, exc_traceback = record.exc_info
|
||||
record.exc_info = traceback.print_exception(exc_type, exc_value, exc_traceback)
|
||||
self.server.handle(pickle.dumps(record))
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue