aboutsummaryrefslogtreecommitdiffstats
path: root/python/sandcrawler/workers.py
diff options
context:
space:
mode:
Diffstat (limited to 'python/sandcrawler/workers.py')
-rw-r--r--python/sandcrawler/workers.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/python/sandcrawler/workers.py b/python/sandcrawler/workers.py
index 597a0ac..356f050 100644
--- a/python/sandcrawler/workers.py
+++ b/python/sandcrawler/workers.py
@@ -108,7 +108,7 @@ class SandcrawlerWorker(object):
"""
return True
- def process(self, task: Any, key: str = None) -> Any:
+ def process(self, task: Any, key: Optional[str] = None) -> Any:
"""
Derived workers need to implement business logic here.
@@ -477,7 +477,7 @@ class ZipfilePusher(RecordPusher):
self.counts["total"] += 1
# NB doesn't really extract the file, just gives you a stream (file-like-object) for reading it
flo = archive.open(zipinfo, "r")
- data = flo.read(2 ** 32)
+ data = flo.read(2**32)
flo.close()
if self.batch_size:
batch.append(data)