mirror of
https://github.com/netinvent/npbackup.git
synced 2025-09-07 05:24:47 +08:00
Cite sources ;)
This commit is contained in:
parent
f9275d7caa
commit
4a51513469
1 changed files with 4 additions and 0 deletions
|
@ -45,6 +45,10 @@ if not "_DEBUG" in globals():
|
|||
|
||||
|
||||
def exception_to_string(exc):
|
||||
"""
|
||||
Transform a catched exception to a string
|
||||
https://stackoverflow.com/a/37135014/2635443
|
||||
"""
|
||||
stack = traceback.extract_stack()[:-3] + traceback.extract_tb(
|
||||
exc.__traceback__
|
||||
) # add limit=??
|
||||
|
|
Loading…
Add table
Reference in a new issue