classification
Title: ValueError in zipfile.ZipFile
Type: behavior Stage:
Components: Library (Lib) Versions: Python 3.7
process
Status: open Resolution:
Dependencies: Superseder:
Assigned To: Nosy List: jvoisin
Priority: normal Keywords:

Created on 2019-12-16 12:58 by jvoisin, last changed 2019-12-16 12:58 by jvoisin.

Files
File name Uploaded Description Edit
crash-4da08e9ababa495ac51ecad588fd61081a66b5bb6e7a0e791f44907fa274ec62 jvoisin, 2019-12-16 12:58
Messages (1)
msg358484 - (view) Author: jvoisin (jvoisin) Date: 2019-12-16 12:58
The attached file produces the following stacktrace when opened via `zipfile.ZipFile`, on Python 3.7.5rc1:

```
$ cat ziprepro.py 
import zipfile
import sys

zipfile.ZipFile(sys.argv[1])
```

```
$ python3 ziprepro.py crash-4da08e9ababa495ac51ecad588fd61081a66b5bb6e7a0e791f44907fa274ec62
Traceback (most recent call last):
  File "ziprepro.py", line 4, in <module>
    zipfile.ZipFile(sys.argv[1])
  File "/usr/lib/python3.7/zipfile.py", line 1225, in __init__
    self._RealGetContents()
  File "/usr/lib/python3.7/zipfile.py", line 1310, in _RealGetContents
    fp.seek(self.start_dir, 0)
ValueError: cannot fit 'int' into an offset-sized integer
```

The ValueError exception isn't documented as a possible exception when using zipfile.ZipFile ( https://docs.python.org/3/library/tarfile.html ).
History
Date User Action Args
2019-12-16 12:58:42jvoisincreate