From 26632881275443890e02694934231523e874c336 Mon Sep 17 00:00:00 2001 From: Marc Beninca Date: Fri, 13 Sep 2024 16:36:29 +0200 Subject: [PATCH] lint/log --- rwx/log/__init__.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/rwx/log/__init__.py b/rwx/log/__init__.py index 5470e67..12fb781 100644 --- a/rwx/log/__init__.py +++ b/rwx/log/__init__.py @@ -1,8 +1,11 @@ +"""Handle logging.""" + import logging import sys def get_file_logger(name: str) -> logging.Logger: + """Return a file logger.""" # formatter formatter = logging.Formatter( "%(name)s: %(asctime)s | %(levelname)s | %(filename)s:%(lineno)s | %(process)d >>> %(message)s", @@ -19,6 +22,7 @@ def get_file_logger(name: str) -> logging.Logger: def get_stream_logger(level: int) -> logging.Logger: + """Return a stream logger.""" # handler out_handler = logging.StreamHandler(stream=sys.stdout) out_handler.setLevel(level)