From f11b440b3f3db97ca6cfb1280468ea306789779f Mon Sep 17 00:00:00 2001 From: Edward Betts Date: Sat, 15 May 2021 14:08:24 +0200 Subject: [PATCH] Bug fix for 'no value' in P31 --- web_view.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/web_view.py b/web_view.py index 1fc6906..f8cf833 100755 --- a/web_view.py +++ b/web_view.py @@ -331,6 +331,9 @@ def get_isa_count(items): for item in items: isa_list = item.get_claim("P31") for isa in isa_list: + if not isa: + print("missing IsA:", item.qid) + continue isa_count[isa["id"]] += 1 return isa_count.most_common()