Handle exception in jsonld signature check

merge-requests/21/head
Bob Mottram 2021-03-14 18:14:18 +00:00
parent 116a696543
commit a19822ce5a
1 changed files with 7 additions and 2 deletions

View File

@ -2378,8 +2378,13 @@ class JsonLdProcessor(object):
# hash bnode paths
path_namer = UniqueNamer('_:b')
path_namer.get_name(bnode)
results.append(self._hash_paths(
bnode, bnodes, namer, path_namer))
try:
bnode_path = self._hash_paths(
bnode, bnodes, namer, path_namer)
results.append(bnode_path)
except BaseException:
print('WARN: jsonld bnode_path failed')
pass
# name bnodes in hash order
cmp_hashes = cmp_to_key(lambda x, y: cmp(x['hash'], y['hash']))