File tree Expand file tree Collapse file tree 3 files changed +3
-1
lines changed Expand file tree Collapse file tree 3 files changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -62,6 +62,7 @@ def format(self, record):
62
62
# user-supplied dict.
63
63
if record .exc_info and not message_dict .get ("exc_info" ):
64
64
message_dict ["exc_info" ] = self .formatException (record .exc_info )
65
+ message_dict ["exc" ] = record .exc_info [0 ].__name__
65
66
if not message_dict .get ("exc_info" ) and record .exc_text :
66
67
message_dict ["exc_info" ] = record .exc_text
67
68
# Display formatted record of stack frames
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ def make_long_description():
14
14
description = "Advanced Python Logger" ,
15
15
long_description = make_long_description (),
16
16
long_description_content_type = "text/markdown" ,
17
- version = "1.0.0 " ,
17
+ version = "1.0.1 " ,
18
18
author = "Fabio Todaro" ,
19
19
license = "MIT" ,
20
20
author_email = "ft@ovalmoney.com" ,
Original file line number Diff line number Diff line change @@ -87,5 +87,6 @@ def test_exception(msg):
87
87
out_dict = json .loads (out )
88
88
89
89
assert out_dict ["exc_info" ] == formatter .formatException (exc_info )
90
+ assert out_dict ["exc" ] == "Exception"
90
91
assert out_dict ["stack_info" ] == "Stack Informations"
91
92
assert out_dict ["test" ] == "test"
You can’t perform that action at this time.
0 commit comments