From bc66be001605454b48a36dd38bffee405bf469ab Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Fri, 12 Feb 2021 11:52:32 -0800 Subject: more seaweedfs hacks --- fatcat_scholar/work_pipeline.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/fatcat_scholar/work_pipeline.py b/fatcat_scholar/work_pipeline.py index cb96274..282378b 100644 --- a/fatcat_scholar/work_pipeline.py +++ b/fatcat_scholar/work_pipeline.py @@ -171,6 +171,10 @@ class WorkPipeline: # print(raw_text) except minio.error.NoSuchKey: return None + except urllib3.exceptions.MaxRetryError: + # HACK: work around broken seaweedfs keys + print(f"seaweedfs failure: sha1hex={fe.sha1}", file=sys.stderr) + return None return dict( raw_text=raw_text, release_ident=release_ident, file_ident=fe.ident, ) @@ -202,6 +206,10 @@ class WorkPipeline: # print(grobid_xml) except minio.error.NoSuchKey: return None + except urllib3.exceptions.MaxRetryError: + # HACK: work around broken seaweedfs keys + print(f"seaweedfs failure: sha1hex={fe.sha1}", file=sys.stderr) + return None return dict( html_meta=html_meta, -- cgit v1.2.3