-
Notifications
You must be signed in to change notification settings - Fork 39
Open
Description
Function main_loop has this code:
try:
log_file = conf.get("LOG_FILE", None)
logger = logging.Logger("TaskManager")
logger.setLevel(logging.DEBUG)
if log_file:
log_level = logging._levelNames.get(conf.get("LOG_LEVEL", "DEBUG").upper())
kobo.log.add_rotating_file_logger(logger, log_file, log_level=log_level)
tm = TaskManager(conf=conf, logger=logger)
except Exception as ex:
raise
sys.stderr.write("Error initializing TaskManager: %s\n" % ex)
sys.exit(1)If some exception occurs it's re-raised instead of executing the code above the raise line. This code is unreachable and it's difficult to know what should be the behavior.
Metadata
Metadata
Assignees
Labels
No labels