Seems to work on master branch though fails on 3.7.
➜ cpython git:(master) ✗ ./python.exe
Python 3.8.0a4+ (heads/master:410b85a7f7, May 13 2019, 21:40:37)
[Clang 7.0.2 (clang-700.1.81)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import zipimport
>>> zipimport.zipimporter("master.zip")
<zipimporter object "master.zip/">
>>> ^D
➜ cpython git:(master) ✗ python3.7
Python 3.7.3 (v3.7.3:ef4ec6ed12, Mar 25 2019, 16:52:21)
[Clang 6.0 (clang-600.0.57)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import zipimport
>>> zipimport.zipimporter("master.zip")
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
zipimport.ZipImportError: not a Zip file: 'master.zip'
➜ cpython git:(996859a90d) ✗ git checkout 5a5ce064b3baadcb79605c5a42ee3d0aee57cdfc
Previous HEAD position was 996859a90d bpo-34790: [docs] Passing coroutines to asyncio.wait() can be confusing. (GH-9543)
HEAD is now at 5a5ce064b3 bpo-5950: Support reading zips with comments in zipimport (#9548)
➜ cpython git:(5a5ce064b3) ✗ make regen-importlib -s && make -s > /dev/null
➜ cpython git:(5a5ce064b3) ✗ ./python.exe -c 'import zipimport; zipimport.zipimporter("master.zip")'
➜ cpython git:(5a5ce064b3) ✗ git checkout 5a5ce064b3baadcb79605c5a42ee3d0aee57cdfc~1
Previous HEAD position was 5a5ce064b3 bpo-5950: Support reading zips with comments in zipimport (#9548)
HEAD is now at 996859a90d bpo-34790: [docs] Passing coroutines to asyncio.wait() can be confusing. (GH-9543)
➜ cpython git:(996859a90d) ✗ make regen-importlib -s && make -s > /dev/null
➜ cpython git:(996859a90d) ✗ ./python.exe -c 'import zipimport; zipimport.zipimporter("master.zip")'
Traceback (most recent call last):
File "<frozen zipimport>", line 89, in __init__
KeyError: 'master.zip'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "<frozen zipimport>", line 91, in __init__
File "<frozen zipimport>", line 366, in _read_directory
zipimport.ZipImportError: not a Zip file: 'master.zip'
Bisecting tells me it could have been fixed with 5a5ce064b3baadcb79605c5a42ee3d0aee57cdfc (issue5950) in 3.8 . Can you please try with a 3.8 release? Download 3.8 alpha 4 : https://www.python.org/downloads/release/python-380a4/
|