From 561dab897b5576391491548614e4db759b89532b Mon Sep 17 00:00:00 2001 From: Christian Wolf Date: Sun, 4 Dec 2022 18:49:20 +0100 Subject: [PATCH] Enable colored logging --- requiremnts.txt | 14 ++++++++++++++ src/main.py | 7 ++++++- 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/requiremnts.txt b/requiremnts.txt index af69cc1..f4c322c 100644 --- a/requiremnts.txt +++ b/requiremnts.txt @@ -1,3 +1,17 @@ +attrs==22.1.0 beautifulsoup4==4.11.1 +colorama==0.4.6 +coloredlogs==15.0.1 +coverage==6.5.0 +exceptiongroup==1.0.1 +humanfriendly==10.0 +iniconfig==1.1.1 +packaging==21.3 +pluggy==1.0.0 +pyparsing==3.0.9 +pytest==7.2.0 +pytest-cov==4.0.0 +pytest-mock==3.10.0 soupsieve==2.3.2.post1 tabulate==0.9.0 +tomli==2.0.1 diff --git a/src/main.py b/src/main.py index b070a8c..0d00a39 100644 --- a/src/main.py +++ b/src/main.py @@ -1,10 +1,15 @@ import solo_turnier import logging +import coloredlogs def __initLogging(): logging.basicConfig() logging.root.setLevel(logging.NOTSET) - return logging.getLogger('solo_turnier') + logger = logging.getLogger('solo_turnier') + + coloredlogs.install(level=5, logger=logger) + + return logger def main(): l = __initLogging()