aboutsummaryrefslogtreecommitdiffstats
path: root/python/scripts
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@archive.org>2020-03-05 01:10:14 -0800
committerBryan Newbold <bnewbold@archive.org>2020-03-05 01:10:14 -0800
commit835d56cafb8f239c8a3ed4c253dfcaba95c6578f (patch)
tree380322141fdb1db265f6e34c7f185c056b8975da /python/scripts
parent5214a7397ee7f4f6e0624bc5ed2b8cb92b66c94f (diff)
downloadsandcrawler-835d56cafb8f239c8a3ed4c253dfcaba95c6578f.tar.gz
sandcrawler-835d56cafb8f239c8a3ed4c253dfcaba95c6578f.zip
ingestrequest_row2json: skip on unicode errors
Diffstat (limited to 'python/scripts')
-rwxr-xr-xpython/scripts/ingestrequest_row2json.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/python/scripts/ingestrequest_row2json.py b/python/scripts/ingestrequest_row2json.py
index 065dd3b..563855d 100755
--- a/python/scripts/ingestrequest_row2json.py
+++ b/python/scripts/ingestrequest_row2json.py
@@ -29,7 +29,10 @@ def run(args):
for l in args.json_file:
if not l.strip():
continue
- req = transform(json.loads(l))
+ try:
+ req = transform(json.loads(l))
+ except:
+ print(l, file=sys.stderr)
print(json.dumps(req, sort_keys=True))
def main():