Log to stderr
This commit is contained in:
parent
5254059fe4
commit
9c180e587b
@ -33,8 +33,8 @@ def setup_logging(config: Dict[str, Any]) -> None:
|
|||||||
# Log level
|
# Log level
|
||||||
verbosity = config['verbosity']
|
verbosity = config['verbosity']
|
||||||
|
|
||||||
# Log to stdout, not stderr
|
# Log to stderr
|
||||||
log_handlers: List[logging.Handler] = [logging.StreamHandler(sys.stdout)]
|
log_handlers: List[logging.Handler] = [logging.StreamHandler(sys.stderr)]
|
||||||
|
|
||||||
if config.get('logfile'):
|
if config.get('logfile'):
|
||||||
log_handlers.append(RotatingFileHandler(config['logfile'],
|
log_handlers.append(RotatingFileHandler(config['logfile'],
|
||||||
|
Loading…
Reference in New Issue
Block a user