Skip to content

Commit

Permalink
Merge pull request #147 from drahnreb/drahnreb/fix-rdflib6-graph-seri…
Browse files Browse the repository at this point in the history
…alize

fix #145 caused by RDFLib/rdflib#1183 (rdflib 6.0.0)

Thanks for the fix @drahnreb!
  • Loading branch information
nicholascar authored Aug 11, 2021
2 parents 38f35af + b5c939f commit ebc60ee
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pylode/profiles/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,7 @@ def _make_schemaorg_metadata(self):
from rdflib.plugin import register, Serializer
register('json-ld', Serializer, 'rdflib_jsonld.serializer', 'JsonLDSerializer')

return g.serialize(format="json-ld").decode("utf-8")
return g.serialize(format="json-ld", encoding="utf-8") # support >= rdflib 6.0.0 and ensure backwards compat (last python 2 release)

def _make_agent_link(self, name, url=None, email=None, affiliation=None):
if self.outputformat == "md":
Expand Down

0 comments on commit ebc60ee

Please sign in to comment.