Skip to content

util.iter_start_of_line() still reads entire lines into memory #22331

@natefoo

Description

@natefoo

#22276 was an attempt to fix unnecessarily high memory usage during set_meta() for sequence filetypes on files with extremely long lines. Unfortunately, this doesn't work, since upon failing to read an entire line, we immediately fall through to an unchunked fh.readline().

Here's a memray-flamegraph showing this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions