Skip to content

Commit 98f6ac1

Browse files
committed
fix: linting
1 parent c315810 commit 98f6ac1

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

azure_functions_worker/logging.py

+2
Original file line numberDiff line numberDiff line change
@@ -91,10 +91,12 @@ def enable_console_logging() -> None:
9191
if logger and handler:
9292
logger.addHandler(handler)
9393

94+
9495
def flush_logger(logger: logging.Logger):
9596
for handler in logger.handlers:
9697
handler.flush()
9798

99+
98100
def is_system_log_category(ctg: str) -> bool:
99101
"""Check if the logging namespace belongs to system logs. Category starts
100102
with the following name will be treated as system logs.

azure_functions_worker/main.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ def main():
4747

4848
import asyncio
4949

50-
5150
from . import logging
5251
from .logging import error_logger, format_exception, logger
5352

@@ -70,6 +69,7 @@ def main():
7069
format_exception(ex)))
7170
raise
7271

72+
7373
def register_sigterm_handler():
7474
import signal
7575
"""
@@ -94,10 +94,10 @@ def handle_sigterm(signum, frame):
9494
# Log the received signal
9595
logger.info(f"SIGTERM received (signal: {signum}). "
9696
"Shutting down gracefully...")
97-
97+
9898
# Log the frame details to see whats executed when the signal was received
9999
logger.info("Frame details at signal receipt:"
100-
f"\n{''.join(traceback.format_stack(frame))}")
100+
f"\n{''.join(traceback.format_stack(frame))}")
101101

102102
DispatcherMeta.__current_dispatcher__ = None
103103

0 commit comments

Comments
 (0)