import logging import logging.config import yaml from os import path if not path.exists("geruecht/log/debug"): a = path.join(path.curdir, "geruecht", "log", "debug") if not path.exists("geruecht/log/info"): b = path.join(path.curdir, "geruecht", "log", "info") with open("geruecht/logging.yml", 'rt') as file: config = yaml.safe_load(file.read()) logging.config.dictConfig(config) def getDebugLogger(): return logging.getLogger("debug_logger") def getCreditLogger(): return logging.getLogger("credit_logger") def getJobsLogger(): return logging.getLogger("jobs_logger")