From ba0601274236667dd6828357e79fe1e19635555d Mon Sep 17 00:00:00 2001 From: François Schmidts Date: Fri, 15 Jan 2016 14:39:49 +0100 Subject: fixing logging --- src/bootstrap.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/bootstrap.py') diff --git a/src/bootstrap.py b/src/bootstrap.py index d790ee2f..cd1e71e4 100644 --- a/src/bootstrap.py +++ b/src/bootstrap.py @@ -10,12 +10,13 @@ from urllib.parse import urlsplit def set_logging(log_path, log_level=logging.INFO, log_format='%(asctime)s %(levelname)s %(message)s'): - logger = logging.getLogger('jarr') formater = logging.Formatter(log_format) handler = logging.FileHandler(log_path) handler.setFormatter(formater) - logger.addHandler(handler) - logger.setLevel(log_level) + for logger_name in ('bootstrap', 'web', 'manager', 'runserver'): + logger = logging.getLogger(logger_name) + logger.addHandler(handler) + logger.setLevel(log_level) from flask import Flask from flask.ext.sqlalchemy import SQLAlchemy -- cgit