From 1bd3c0c9de01555435559b242c864fcd2a712579 Mon Sep 17 00:00:00 2001 From: emkael Date: Fri, 26 Jul 2019 10:09:46 +0200 Subject: Logging facilities for GUI --- playoff.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'playoff.py') diff --git a/playoff.py b/playoff.py index 4e4d197..9531ca0 100644 --- a/playoff.py +++ b/playoff.py @@ -1,4 +1,4 @@ -import traceback +import logging, traceback from jfr_playoff.filemanager import PlayoffFileManager from jfr_playoff.generator import PlayoffGenerator @@ -26,9 +26,10 @@ def main(): type=str, nargs='?', default=None) arguments = arg_parser.parse_args() - PlayoffLogger.setup('ERROR' if arguments.quiet else ( - 'INFO' if arguments.verbose else ( - 'DEBUG' if arguments.debug else 'WARNING'))) + PlayoffLogger.setup( + level=logging.ERROR if arguments.quiet else ( + logging.INFO if arguments.verbose else ( + logging.DEBUG if arguments.debug else logging.WARNING))) PlayoffLogger.get().info('started with arguments: %s', arguments) -- cgit v1.2.3