Commit 2cc45d87 authored by Ad Schellevis's avatar Ad Schellevis Committed by Franco Fichtner

(proxy) regression in zip file download

(cherry picked from commit 83627572)
parent e2a771e2
......@@ -55,7 +55,6 @@ class Downloader(object):
self._url = url
self._timeout = timeout
self._source_handle = None
self._target_data = None
def fetch(self):
""" fetch (raw) source data into tempfile using self._source_handle
......@@ -107,8 +106,7 @@ class Downloader(object):
compression=zipfile.ZIP_DEFLATED) as zf:
for item in zf.infolist():
if item.file_size > 0:
yield item.filename, zf.read(item)
self._target_data = target_data
yield item.filename, zf.open(item)
else:
yield os.path.basename(self._url), self._source_handle
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment