Skip to content

Remove unneeded ZipFile IO #89668

Closed

Description

@data-ux
mannequin
BPO 45505
Nosy @data-ux
PRs
  • bpo-45505: ZipFile file header optimization #25966
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = None
    created_at = <Date 2021-10-18.05:30:14.320>
    labels = ['library', 'performance']
    title = 'Remove unneeded ZipFile IO'
    updated_at = <Date 2021-10-18.05:30:14.320>
    user = 'https://github.com/data-ux'

    bugs.python.org fields:

    activity = <Date 2021-10-18.05:30:14.320>
    actor = 'data-ux'
    assignee = 'none'
    closed = False
    closed_date = None
    closer = None
    components = ['Library (Lib)']
    creation = <Date 2021-10-18.05:30:14.320>
    creator = 'data-ux'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 45505
    keywords = []
    message_count = 1.0
    messages = ['404155']
    nosy_count = 1.0
    nosy_names = ['data-ux']
    pr_nums = ['25966']
    priority = 'normal'
    resolution = None
    stage = None
    status = 'open'
    superseder = None
    type = 'performance'
    url = 'https://bugs.python.org/issue45505'
    versions = []

    Activity

    1. data-ux commented on Oct 18, 2021

      data-uxmannequin
      MannequinAuthor

      Currently in the ZipFile class implementation, when processing the zip file headers "extra" field, a .read() call is used without using the returned value in any way. This call could be replaced with a .seek() to avoid actually doing the IO.

      The change would improve performance in use cases where the fileobject given to ZipFile is backed by high latency IO, eg. HTTP range requests.

    2. added
      stdlibStandard Library Python modules in the Lib/ directory
      performancePerformance or resource usage
      on Oct 18, 2021
    3. transferred this issue fromon Apr 10, 2022
    4. added a commit that references this issue on May 15, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Metadata

    Metadata

    Assignees

    No one assigned

      Labels

      performancePerformance or resource usagestdlibStandard Library Python modules in the Lib/ directory

      Projects

      No projects

        Milestone

        No milestone

        Relationships

        None yet

        Development

        No branches or pull requests

        Issue actions