-
Notifications
You must be signed in to change notification settings - Fork 71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Broken Markdown generation with pyLODE examples.ttl #155
Comments
Thanks for picking this up @orieg. I think I've fixed this issue: a Publisher, or any other Agent, will have a name generated from its URL if no actual name is given. So the HTML for the examples.ttl example should now have this in it Let me know if you see this working in your copy of |
I think there's a different root issue @nicholascar, rdflib seems to have switched from using Unfortunately this also means that ontologies that used to be formatted just fine with previous versions are now broken. All the checks in def _make_agent(self, agent_node):
name = None
url = None
for p, o in self.G.predicate_objects(subject=agent_node):
if p in [FOAF.homepage, SDO.identifier]:
url = str(o)
elif p in [FOAF.name, SDO.name]:
name = str(o) Are now trying to match the http variants of the URIs. I think we could add some more statement to the |
I haven't tested @nicholascar update yet. Though, I would agree with @hdelva that the root problem seems to be a bit more "deep". For example:
Note that |
It does look like there's a problem with upstream RDFlib. It should indeed be |
The schema.org HTTPS issue was fixed in RDFlib the other day and I've fixed the Markdown list issue. I've updated the example file that showed the issues too. |
So it's fixed in |
pyLODE version: 2.12.0
Issue Reproduction Turtle File: examples.ttl
Two problems occurs when generating the pyLODE examples.ttl file:
dcterms:creator
anddcterms:publisher
will render as "None" when schema.org is using https@prefix sdo: <https://schema.org/> .
. A workaround is to convert to@prefix sdo: <http://schema.org/> .
which is not correct according to #121. Also, this workaround will prevent thesdo:codeRepository
to work and completely fail the rendering with the errorIndexError: list index out of range
. You will need to define yet another schema prefix using https to get around it.<li>
tags at the beginning which breaks the rest of the rendering. This does not occur with the following Object properties section.Sample output of incorrect rendering
Expected output
Sample code to reproduce:
Using the latest examples.ttl from the official repo, you can use the below code.
The text was updated successfully, but these errors were encountered: