Clean log module

This commit is contained in:
Guillaume Ayoub 2013-07-12 15:12:07 +02:00
parent af30483f69
commit 18f5c334f1

View File

@ -34,6 +34,7 @@ from . import config
LOGGER = logging.getLogger() LOGGER = logging.getLogger()
def start(): def start():
filename = os.path.expanduser(config.get("logging", "config")) filename = os.path.expanduser(config.get("logging", "config"))
debug = config.getboolean("logging", "debug") debug = config.getboolean("logging", "debug")
@ -53,5 +54,6 @@ def start():
LOGGER.addHandler(handler) LOGGER.addHandler(handler)
if debug: if debug:
LOGGER.setLevel(logging.DEBUG) LOGGER.setLevel(logging.DEBUG)
LOGGER.debug("Logging configuration file '%s' not found, using stdout." LOGGER.debug(
% filename) "Logging configuration file '%s' not found, using stdout." %
filename)