klippy: properly set log level when logging to stderr
The `logging.basicConfig` does not reconfigure default logger. This results in printing only warnings/errors to stderr instead of also info (or debug). This fixes the issue by setting log level on root logger. Signed-off-by: Kamil Trzciński <ayufan@ayufan.eu>
This commit is contained in:
parent
6ad6e39ad2
commit
045455648a
|
@ -342,7 +342,7 @@ def main():
|
||||||
start_args['log_file'] = options.logfile
|
start_args['log_file'] = options.logfile
|
||||||
bglogger = queuelogger.setup_bg_logging(options.logfile, debuglevel)
|
bglogger = queuelogger.setup_bg_logging(options.logfile, debuglevel)
|
||||||
else:
|
else:
|
||||||
logging.basicConfig(level=debuglevel)
|
logging.getLogger().setLevel(debuglevel)
|
||||||
logging.info("Starting Klippy...")
|
logging.info("Starting Klippy...")
|
||||||
start_args['software_version'] = util.get_git_version()
|
start_args['software_version'] = util.get_git_version()
|
||||||
start_args['cpu_info'] = util.get_cpu_info()
|
start_args['cpu_info'] = util.get_cpu_info()
|
||||||
|
|
Loading…
Reference in New Issue