Skip to content
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

Problem loading ontology from an N-triples file #23

Open
moissinac opened this issue Apr 12, 2022 · 1 comment
Open

Problem loading ontology from an N-triples file #23

moissinac opened this issue Apr 12, 2022 · 1 comment

Comments

@moissinac
Copy link

Hello
I'm testing owlready2 which seems interesting.
But, I'm encoutering problem with the loading phase of one of my files with
senneville_ontology= get_ontology("file://c://wamp64/www/barbules/ontologies/test.nt").load()
where test.nt contains only one line
<http://barbules.givingsense.eu/ontologies/barbules/SENNEVILLE> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2002/07/owl#NamedIndividual> .
I'm getting the following error:
...
File "C:\wamp64\www\CPD\trials\venv\lib\site-packages\owlready2\rdfxml_2_ntriples.py", line 315, in parse
raise OwlReadyOntologyParsingError("RDF/XML parsing error in file %s, line %s, column %s." % (getattr(f, "name", getattr(f, "url", "???")), parser.CurrentLineNumber, parser.CurrentColumnNumber)) from e
owlready2.base.OwlReadyOntologyParsingError: RDF/XML parsing error in file c://wamp64/www/barbules/ontologies/test.nt, line 1, column 7.
So, the file is recognized as being an N-triples file, but the parser fails to parse it.

@seankim658
Copy link

Also getting this issue, can't load any owl files. Interestingly, if you try this in a jupyter notebook it always fails but then if I run the cell again it loads. Quite frustrating as I can't use this module in python files at all, only in notebooks with that weird workaround.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants