mirror of https://github.com/scrapy/scrapy.git
fixed scrapy.utils.gz.gunzip() broken after changes from Python 2.7.3 to 2.7.4
This commit is contained in:
parent
29a12af1b0
commit
4dc76e7cca
|
|
@ -0,0 +1,5 @@
|
|||
Twisted>=8.0
|
||||
w3lib>=1.2
|
||||
queuelib
|
||||
lxml
|
||||
pyOpenSSL
|
||||
|
|
@ -14,7 +14,7 @@ def gunzip(data):
|
|||
try:
|
||||
chunk = f.read(8196)
|
||||
output += chunk
|
||||
except (IOError, struct.error):
|
||||
except (IOError, EOFError, struct.error):
|
||||
# complete only if there is some data, otherwise re-raise
|
||||
# see issue 87 about catching struct.error
|
||||
# some pages are quite small so output is '' and f.extrabuf
|
||||
|
|
|
|||
Loading…
Reference in New Issue