Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

zipimport.zipimporter breaks for zips containing files with size > 0xFFFFFFFF #118107

Closed
Labels
3.13bugs and security fixesrelease-blockertype-bugAn unexpected behavior, bug, or error
@jsirois

Description

@jsirois

Bug report

Bug description:

The following test in the Pex project fails under CPython 3.13.0a6:
https://github.com/pex-tool/pex/blob/27c2db2bf26039bef41323c964bc4e0317a7b4f5/tests/test_pex_builder.py#L520-L547

The failure includes stderr output from zipimporter like:

Failed checking if argv[0] is an import path entryTraceback (most recent call last):  File "<frozen zipimport>", line 98, in __init__  File "<frozen zipimport>", line 520, in _read_directoryNameError: name 'struct' is not defined. Did you forget to import 'struct'?  File "/tmp/pytest-of-jsirois/pytest-14/test_check0/too-big.pyz", line 1    PK-SyntaxError: source code cannot contain null bytes

Inspection of#94146 indicates the code added to handle too large files is missing an import:https://github.com/python/cpython/pull/94146/files#r1572552939 The tests added in that PR do stress too many files for a 32 bit zip, but they do not stress too big a file for a 32 bit zip; so it makes sense that this import omission slipped past.

CPython versions tested on:

3.13, CPython main branch

Operating systems tested on:

Linux

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    3.13bugs and security fixesrelease-blockertype-bugAn unexpected behavior, bug, or error

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp