From c1196ea5d16f495125cb6032ff0802c33e6c659b Mon Sep 17 00:00:00 2001 From: Timo Date: Tue, 23 Jan 2024 15:27:52 +0100 Subject: [PATCH] fixes --- src/sparqlunicorn_ontdoc/export/data/voidexporter.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/sparqlunicorn_ontdoc/export/data/voidexporter.py b/src/sparqlunicorn_ontdoc/export/data/voidexporter.py index 59b7e3f5..9f9c4568 100644 --- a/src/sparqlunicorn_ontdoc/export/data/voidexporter.py +++ b/src/sparqlunicorn_ontdoc/export/data/voidexporter.py @@ -57,7 +57,7 @@ def createVoidDataset(dsname,prefixnamespace,deploypath,outpath,licenseuri,modti URIRef("http://rdfs.org/ns/void#Dataset"))) g.add((URIRef(cururi),URIRef("http://rdfs.org/ns/void#property"),URIRef(pred))) g.add((URIRef(cururi),URIRef("http://rdfs.org/ns/void#triples"),Literal(str(propstats[pred]["triples"]),datatype="http://www.w3.org/2001/XMLSchema#integer"))) - subjects.add(cururi) + subjects.add(URIRef(cururi)) for item in classtree["core"]["data"]: if item["type"]=="class": cururi = voidds +"_"+ DocUtils.shortenURI(item["id"]) @@ -66,7 +66,7 @@ def createVoidDataset(dsname,prefixnamespace,deploypath,outpath,licenseuri,modti g.add((URIRef(cururi), URIRef("http://rdfs.org/ns/void#class"), URIRef(item["id"]))) if item["id"] in objectmap: g.add((URIRef(cururi), URIRef("http://rdfs.org/ns/void#entities"),Literal(str(objectmap[item["id"]]), datatype="http://www.w3.org/2001/XMLSchema#integer"))) - subjects.add(cururi) + subjects.add(URIRef(cururi)) for prop in nonnscount: for ns in nonnscount[prop]: cururi=voidds+"_"+DocUtils.shortenURI(ns) @@ -75,7 +75,7 @@ def createVoidDataset(dsname,prefixnamespace,deploypath,outpath,licenseuri,modti g.add((URIRef(cururi), URIRef("http://rdfs.org/ns/void#objectsTarget"),URIRef(ns))) g.add((URIRef(cururi), URIRef("http://rdfs.org/ns/void#linkPredicate"),URIRef(prop))) g.add((URIRef(cururi), URIRef("http://rdfs.org/ns/void#triples"),Literal(str(nonnscount[prop][ns]),datatype="http://www.w3.org/2001/XMLSchema#integer"))) - subjects.add(cururi) + subjects.add(URIRef(cururi)) g.serialize(outpath+"/void.ttl", encoding="utf-8") return {"graph":g,"subjects":subjects}