aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xmapreduce/extraction_cdx_grobid.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/mapreduce/extraction_cdx_grobid.py b/mapreduce/extraction_cdx_grobid.py
index 2515cba..f6c1ec1 100755
--- a/mapreduce/extraction_cdx_grobid.py
+++ b/mapreduce/extraction_cdx_grobid.py
@@ -143,9 +143,9 @@ class MRExtractCdxGrobid(MRJob):
info['grobid0:status_code'] = grobid_response.status_code
if grobid_response.status_code != 200:
# response.text is .content decoded as utf-8
- info['grobid0:status'] = json.loads(grobid_response.text)
+ info['grobid0:status'] = dict(description=grobid_response.text)
return info, dict(status="error", reason="non-200 GROBID HTTP status",
- extra=grobid_response.content)
+ extra=grobid_response.text)
info['grobid0:status'] = {'status': 'success'}
info['grobid0:tei_xml'] = grobid_response.content