mirror of
https://github.com/archlinux-jerry/buildbot
synced 2024-11-25 14:30:40 +08:00
utils: change notify level to info
This commit is contained in:
parent
7f807b3197
commit
82cf5c7c14
1 changed files with 3 additions and 7 deletions
10
utils.py
10
utils.py
|
@ -285,11 +285,8 @@ def configure_logger(logger, format='%(asctime)s - %(name)-18s - %(levelname)s -
|
||||||
return fmtr
|
return fmtr
|
||||||
|
|
||||||
logger.setLevel(logging.DEBUG)
|
logger.setLevel(logging.DEBUG)
|
||||||
fnotify = cnotify = False
|
fformatter = ExceptionFormatter(fmt=format, notify=False)
|
||||||
fnotify = True if enable_notify and logfile else False
|
cformatter = ExceptionFormatter(fmt=format, notify=True)
|
||||||
cnotify = True if enable_notify and (not logfile) else False
|
|
||||||
fformatter = ExceptionFormatter(fmt=format, notify=fnotify)
|
|
||||||
cformatter = ExceptionFormatter(fmt=format, notify=cnotify)
|
|
||||||
logging.addLevelName(49, 'Exception')
|
logging.addLevelName(49, 'Exception')
|
||||||
# create file handler
|
# create file handler
|
||||||
if logfile:
|
if logfile:
|
||||||
|
@ -311,7 +308,6 @@ def configure_logger(logger, format='%(asctime)s - %(name)-18s - %(levelname)s -
|
||||||
assert type(consolelog) is str
|
assert type(consolelog) is str
|
||||||
cfh = logging.FileHandler(consolelog)
|
cfh = logging.FileHandler(consolelog)
|
||||||
cfh.setLevel(level)
|
cfh.setLevel(level)
|
||||||
cfhformatter = ExceptionFormatter(fmt=format, notify=False)
|
cfh.setFormatter(cformatter)
|
||||||
cfh.setFormatter(cfhformatter)
|
|
||||||
logger.addHandler(cfh)
|
logger.addHandler(cfh)
|
||||||
# for client.printlog
|
# for client.printlog
|
||||||
|
|
Loading…
Reference in a new issue