You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Create modular packages for zipfile and test_zipfile #98098
I'm about to embark on once again syncing changes from zipp to zipfile.
Historically, I've manually copied the contents of the cpython branch to the relevant files in this repository, but that process is error prone (because it involves syncing a whole file to a portion of another file).
I'd like to instead create packages for zipfile and test_zipfile, such that the functionality that's synced with zipp can be kept separate from other zipfile functionality. Moreover, late versions of zipp bring in extra dependencies so a package can also serve as a home to vendor such functionality.
I'm not suggesting to change the user's signature at all. The names will still be presented through the zipfile module unchanged.
I tried moving most of zipfile.py to zipfile/_core.py but that caused problems with all of the global constants in that file, many of which are treated as mutable (at least for tests).
Hello, looks like this issue has lead to warning <frozen runpy>:128: RuntimeWarning: 'zipfile.__main__' found in sys.modules after import of package 'zipfile', but prior to execution of 'zipfile.__main__'; this may result in unpredictable behaviour when using https://docs.python.org/3/library/zipfile.html#command-line-interface
Activity
pythongh-98098: Move zipfile into a package.
pythongh-98098: Move zipfile into a package.
jaraco commentedon Oct 8, 2022
I tried moving most of
zipfile.pytozipfile/_core.pybut that caused problems with all of the global constants in that file, many of which are treated as mutable (at least for tests).pythongh-98098: Remove _core.
pythongh-98098: Move zipfile into a package.
pythongh-98098: Move zipfile into a package.
Move files to a location matching their downstream published location…
Merge branch 'main' into pythongh-98098/zipfile-packages
Merge branch 'main' into pythongh-98098/zipfile-packages
gh-98098: Create packages from zipfile and test_zipfile (gh-98103)
gh-98108: Add limited pickleability to zipfile.Path (GH-98109)
hauntsaninja commentedon Nov 29, 2022
Looks like this can be closed, but not touching it since I see it was assigned to Yhg1s and I don't know what that means
ilia1243 commentedon Dec 1, 2023
Hello, looks like this issue has lead to warning
<frozen runpy>:128: RuntimeWarning: 'zipfile.__main__' found in sys.modules after import of package 'zipfile', but prior to execution of 'zipfile.__main__'; this may result in unpredictable behaviourwhen using https://docs.python.org/3/library/zipfile.html#command-line-interfacegpshead commentedon Dec 1, 2023
please file a new issue if you believe there is a bug with instructions for how to reproduce it.
hauntsaninja commentedon Dec 1, 2023
Thanks ilia1243 for reporting! I opened an issue at #112578 and a PR at #112579