Returns the level for the inputed logger.
        
        :param      logger | <str>
        
        :return     <int>
344169
def loggerLevel(self, logger):
        
        try:
            return self._loggerLevels[logger]
        except KeyError:
            items = sorted(self._loggerLevels.items())
            for key, lvl in items:
                if logger.startswith(key):
                    return lvl
            return logging.NOTSET
792861
def log_level_type(arg):
	""""""
	if not arg.upper() in ('NOTSET', 'DEBUG', 'INFO', 'WARNING', 'ERROR', 'CRITICAL'):
		raise argparse.ArgumentTypeError("{0} is not a valid log level".format(repr(arg)))
	return getattr(logging, arg.upper())
778633
def log_level(self,
              level: typing.Union[str, int]=None,
              *args,
              **kwargs) -> typing.Union[None, str]:
    
    if level is None:
        return self.root_logger.getEffectiveLevel()
    # NOTE: `setLevel` takes both string and integers. Try to cast to an integer first
    try:
        value = int(level)
    # if we can't cast to an int, it's probably a string
    except ValueError:
        pass

    self.root_logger.setLevel(value)
457808
def get_logging_level(debug):
    """"""
    level = logging.INFO
    if debug:
        level = logging.DEBUG
    return level
48741
def logging_levels():
    
    enabled = strtobool(request.headers.get("x-request-debug", "false"))
    level = None
    try:
        if enabled:
            level = getLogger().getEffectiveLevel()
            getLogger().setLevel(DEBUG)
        yield
    finally:
        if enabled:
            getLogger().setLevel(level)
1122362
def set_level(logger=None, log_level=None):
    '''

    '''
    log_level = logging.getLevelName(os.getenv('VERBOSITY', 'WARNING'))
    logging.getLogger(logger).setLevel(log_level)
1374689
function Logger(level) {
    if (_.isString(level) && _.has(LogLevel, level)) {
        this.level = LogLevel[level];    
    } else if (_.isNumber(level) && level >= 0 && level <= 4) {
        this.level = level;
    } else {
        this.level = LogLevel.info;
    }    
}
1081165
@NotNull
	public static ILogger getLogger(@Nullable ILogger logger) {
		return logger == null ? new NullLogger() : logger;
	}
1368254
def level(self) -> str:
        
        levels = self._data['level']
        return self.random.choice(levels)
560430
def _get_logger(self):
        

        if self.logger:
            return self.logger
        elif self.server:
            return self.server.logger
        else:
            return default_logger
218130
def setLoggerLevel(self, logger, level):
        
        if level == logging.NOTSET:
            self.removeLogger(logger)
            self.handler().setLoggerLevel(logger, level)
            return
            
        if isinstance(logger, logging.Logger):
            logger = logger.name
        
        if not logger in self._loggers:
            self.addLogger(logger, level)
        else:
            self.handler().setLoggerLevel(logger, level)
827832
def get_logger(name=None):
    

    level = logging.CRITICAL
    if DEBUG:
        logging.disable(logging.NOTSET)
        level = logging.DEBUG

    if name is None:
        name = "<unknown>"

    log = logging.getLogger(name=name)
    log.setLevel( level )
    console = logging.StreamHandler()
    console.setLevel( level )
    log_format = ('[%(asctime)s] [%(levelname)s] [%(module)s:%(lineno)d] (' + str(os.getpid()) + '.%(thread)d) %(message)s' if DEBUG else '%(message)s')
    formatter = logging.Formatter( log_format )
    console.setFormatter(formatter)
    log.propagate = False

    if len(log.handlers) > 0:
        for i in xrange(0, len(log.handlers)):
            log.handlers.pop(0)
    
    log.addHandler(console)
    return log
1208043
def setLevel(self, level):
		
		if isinstance(level, int):
			self.logger.setLevel(level)
			return

		# level en tant que string
		level = level.lower()
		if level == "debug":
			self.logger.setLevel(logging.DEBUG)

		elif level == "info":
			self.logger.setLevel(logging.INFO)

		elif level == "warning" or level == "warning":
			self.logger.setLevel(logging.WARN)

		elif level == "error":
			self.logger.setLevel(logging.ERROR)

		else:
			# par défaut
			self.logger.setLevel(logging.INFO)
1315329
def level(self, lvl=None):
        ''''''
        if not lvl:
            return self._lvl
        self._lvl = self._parse_level(lvl)
        self.stream.setLevel(self._lvl)
        logging.root.setLevel(self._lvl)
199867
def getLogger(*args, **kwargs):
    
    logger = logging.getLogger(*args, **kwargs)
    if _overrideLogLevel is not None:
        logger.setLevel(logging.NOTSET)
    return logger
1043674
public String getLoggerLevel(String loggerName) throws Exception {
        Address addr = Address.root().add(SUBSYSTEM, LOGGING, LOGGER, loggerName);
        return getStringAttribute("level", addr);
    }
160665
def get_logger(logger_name):
    

    # Use default global logger
    if logger_name is None:
        return __instance

    assert isinstance(logger_name, str), 'Logger name must be a string!'

    with __lock:
        if logger_name in __loggers:
            return __loggers[logger_name]

        logger_instance = LogOne(logger_name=logger_name)
        __loggers[logger_name] = logger_instance
        return logger_instance