diff options
Diffstat (limited to 'kvmd/logging.py')
-rw-r--r-- | kvmd/logging.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/kvmd/logging.py b/kvmd/logging.py index e012e8f9..894f12af 100644 --- a/kvmd/logging.py +++ b/kvmd/logging.py @@ -21,12 +21,16 @@ import sys +import types import logging +from typing import Optional + # ===== def get_logger(depth: int=1) -> logging.Logger: - frame = sys._getframe(1) # pylint: disable=protected-access + frame: Optional[types.FrameType] = sys._getframe(1) # pylint: disable=protected-access + assert frame frames = [] while frame: frames.append(frame) |