mirror of
https://github.com/norohind/jubilant-system-core.git
synced 2025-04-14 18:40:31 +03:00
Remove print traceback from shutdown_callback
This commit is contained in:
parent
a3a87edea1
commit
52437392df
3
main.py
3
main.py
@ -1,7 +1,6 @@
|
||||
from loguru import logger
|
||||
|
||||
import time
|
||||
import traceback
|
||||
|
||||
import FAPI
|
||||
import signal
|
||||
@ -22,7 +21,7 @@ def shutdown_callback(sig: int, frame) -> None:
|
||||
frame_info = inspect.getframeinfo(frame)
|
||||
func = frame_info.function
|
||||
code_line = frame_info.code_context[0]
|
||||
logger.info(f'Currently at {func}:{frame_info.lineno}: {code_line!r}\n{traceback.print_tb(frame)}')
|
||||
logger.info(f'Currently at {func}:{frame_info.lineno}: {code_line!r}')
|
||||
|
||||
except Exception as e:
|
||||
logger.info(f"Can't detect where we are because {e}")
|
||||
|
Loading…
x
Reference in New Issue
Block a user