def make_log_record_output(category, level, message, format=None, datefmt=None, **kwargs):
 if ((not category) or (category == '__ROOT__')):
  category = 'root'
 levelname = logging.getLevelName(level)
 record_data = dict(name=category, levelname=levelname, msg=message)
 record_data.update(kwargs)
 record = logging.makeLogRecord(record_data)
 formatter = logging.Formatter(format, datefmt=datefmt)
 return formatter.format(record)

def make_log_record_output ( category , level , message , format = None , datefmt = None , ** kwargs ) : if ( ( not category ) or ( category == '__ROOT__' ) ) : category = 'root' levelname = logging . getLevelName ( level ) record_data = dict ( name = category , levelname = levelname , msg = message ) record_data . update ( kwargs ) record = logging . makeLogRecord ( record_data ) formatter = logging . Formatter ( format , datefmt = datefmt ) return formatter . format ( record )
create the output for a log record .