Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(1)  |  Call(1)  |  Derive(0)  |  Import(0)

        def translate_lines(translated_lines, verbose=False):
    translatedLines = []
    currentLine = None

    for number, line in enumerate(translated_lines):
        if line_is_a_new_entry(line):
            if currentLine != None:
                translatedLines.append(currentLine)
            if verbose:
                print line.raw
            set_timestamp_speaker_and_text(line)
            currentLine = line
        elif currentLine != None:
            if line.raw.strip():
                if is_a_non_log_line(line):
                    currentLine.append_non_log_line(line.raw.strip())
                else:
                    currentLine.append_text(line.raw)
        else:
            errors.append("Line %i has no nominal timestamp: %s" % (number+1, line.raw))
    
    translatedLines.append(currentLine)
    
    return translatedLines          
        


src/s/p/Spacelog-HEAD/mcshred/src/MCShredTest.py   Spacelog(Download)
        shreddedLines = MCShred.shred_to_lines(logLines)
 
        translatedLines = MCShred.translate_lines(shreddedLines)
 
        print(translatedLines[0].text)