Ejemplo n.º 1
0
def log_(msg, level):
    """ generic logging function """
    #(caller, filename) = scc.findcaller(3)
    filename = scc.findcaller(3)[1]
    module = filename.split("/")[-1][0:-3]

    logger = logging.getLogger(module)
    getattr(logger, level)(msg)
Ejemplo n.º 2
0
def retrieve_config_infos(self):
    """ retrieve config info """
    caller = __scc.findcaller(2)[0]
    config = __config.get_config(__USERS_CONFIGFILE, [self.systemtype])
    return config.get_section(caller)