if we have a logging config file, use it
this ensures that we don't break upstream logging configuration by setting levels too early. Change-Id: Idc759da2877f28cbb258bdbc302921605e3299f6
This commit is contained in:
parent
a641283270
commit
cd37ee2369
@ -316,9 +316,6 @@ def setup_logging(config):
|
||||
"pyelasticsearch": logging.INFO,
|
||||
"requests.packages.urllib3.connectionpool": logging.WARN
|
||||
}
|
||||
for module in loglevels:
|
||||
log = logging.getLogger(module)
|
||||
log.setLevel(loglevels[module])
|
||||
|
||||
if config.has_option('ircbot', 'log_config'):
|
||||
log_config = config.get('ircbot', 'log_config')
|
||||
@ -332,6 +329,9 @@ def setup_logging(config):
|
||||
format=FORMAT,
|
||||
datefmt=DATEFMT
|
||||
)
|
||||
for module in loglevels:
|
||||
log = logging.getLogger(module)
|
||||
log.setLevel(loglevels[module])
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
Loading…
x
Reference in New Issue
Block a user