From aad5c140ddec8c365e3cd3f86a8cff14e50fb758 Mon Sep 17 00:00:00 2001 From: Marc Beninca Date: Mon, 10 Jun 2024 12:52:19 +0200 Subject: [PATCH] =?UTF-8?q?=E2=88=92#?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- rwx/log/__init__.py | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/rwx/log/__init__.py b/rwx/log/__init__.py index 4d28f82..b951ac9 100644 --- a/rwx/log/__init__.py +++ b/rwx/log/__init__.py @@ -1,22 +1,16 @@ import logging import sys - - def get_logger(name: str) -> logging.Logger: formatter = logging.Formatter( "%(name)s: %(asctime)s | %(levelname)s | %(filename)s:%(lineno)s | %(process)d >>> %(message)s", ) - - # file_handler = logging.FileHandler('log.txt') - # file_handler.setFormatter(formatter) - # file_handler.setLevel(logging.INFO) - + # out_handler = logging.StreamHandler(stream=sys.stdout) out_handler.setFormatter(formatter) out_handler.setLevel(logging.INFO) - + # logger = logging.getLogger(name) - # logger.addHandler(file_handler) logger.addHandler(out_handler) logger.setLevel(logging.INFO) + # return logger