Merge pull request #2446 from hroff-1902/log-stderr

Log to stderr
This commit is contained in:
Matthias 2019-11-01 06:14:55 +01:00 committed by GitHub
commit 880834b902
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -33,8 +33,8 @@ def setup_logging(config: Dict[str, Any]) -> None:
# Log level
verbosity = config['verbosity']
# Log to stdout, not stderr
log_handlers: List[logging.Handler] = [logging.StreamHandler(sys.stdout)]
# Log to stderr
log_handlers: List[logging.Handler] = [logging.StreamHandler(sys.stderr)]
if config.get('logfile'):
log_handlers.append(RotatingFileHandler(config['logfile'],