Add time and level to default logging formatter

This commit is contained in:
Adriane Boyd 2021-02-15 14:09:33 +01:00
parent 1e3a326e53
commit a3293efc48
1 changed files with 1 additions and 1 deletions

View File

@ -70,7 +70,7 @@ CONFIG_SECTION_ORDER = ["paths", "variables", "system", "nlp", "components", "co
logger = logging.getLogger("spacy") logger = logging.getLogger("spacy")
logger_stream_handler = logging.StreamHandler() logger_stream_handler = logging.StreamHandler()
logger_stream_handler.setFormatter(logging.Formatter("%(message)s")) logger_stream_handler.setFormatter(logging.Formatter("[%(asctime)s] [%(levelname)s] %(message)s"))
logger.addHandler(logger_stream_handler) logger.addHandler(logger_stream_handler)