def METHOD_NAME(buff):
    logs = []
    line, sep, buff = buff.partition('\n')
    while sep and line:
        logs.append(LogLine(line))
        line, sep, buff = buff.partition('\n')
    if not sep:
        buff = line  # we put back the last unterminated line in the buffer
    return logs, buff