def emit(self, record):
record.task = self.cur_task<EOL>if record.levelno >= self.dump_level and self.cur_task:<EOL><INDENT>self.tasks[self.cur_task].failed = True<EOL>self.tasks[self.cur_task].force_show = True<EOL><DEDENT>is_start = START_TASK_REG.match(str(record.msg))<EOL>if is_start:<EOL><INDENT>self.handle_new_task(is_start.groupdict()['<STR_LIT>'], record)<EOL>return<EOL><DEDENT>is_end = END_TASK_REG.match(str(record.msg))<EOL>if is_end:<EOL><INDENT>self.handle_closed_task(is_end.groupdict()['<STR_LIT>'], record)<EOL>return<EOL><DEDENT>force_show_record = ALWAYS_SHOW_REG.match(str(record.msg))<EOL>if force_show_record:<EOL><INDENT>record.msg = force_show_record.groupdict()['<STR_LIT:message>']<EOL>self.pretty_emit(record)<EOL><DEDENT>if (<EOL>not force_show_record and self.should_show_by_level(record)<EOL>and self.should_show_by_depth()<EOL>):<EOL><INDENT>self.pretty_emit(record)<EOL>return<EOL><DEDENT>if self.cur_task:<EOL><INDENT>self.tasks[self.cur_task].append(record)<EOL><DEDENT>
Handle the given record, this is the entry point from the python
logging facility

Params:
    record (logging.LogRecord): log record to handle

Returns:
    None