-
Notifications
You must be signed in to change notification settings - Fork 315
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
Saving fails for ontologies containing XMLLiteral #495
Comments
|
Yes, that makes sense. It is easy to reproduce just by opening the file with the OWL API and saving it. I added some test case that we were using.
|
I spotted that last night but then wasn't sure what the correct behavior is
(I believe that the current behavior is incorrect but I'm not sure which
part :).
I don't remember how much of the surface form is part of the literal value,
and if the namespace must be preserved. If namespaces can always be
expanded then that might make sense, especially if the literal is used in
other formats.
Time to read the rdf/XML spec. But first I should clean the cat box.
|
I think the name space declaration must be preserved. It is possible that
any name spaces used in the literal may need to be added, but that is
deeper in the xslt weeds than I care to go.
If the latter is true then it must happen during the RDF/XML parse prior to
the construction of the literal value.
|
Of course, then two xml literals are not structurally equivalent. I think.
|
Indeed. The XML literal must be a self contained XML fragment, i.e., not rely on the surrounding RDF/XML to provide anything
Probably not - the idea is that the literal can verbatim be moved about or to other ontologies. That's where the requirement to be self contained comes from, far as I understand it. |
I think that you ought to be right, but I'm not yet sure about whether non However preserving the declarations in the current example is definitely
|
Example 9 is not self contained either - the |
Hi @ignazio1977. I'm wondering what your timeline is for making this fix part of a release in Maven Central? BioPortal is using version 4.1.0 of the owlapi-distribution, and we're unable to make the latest version of the NCI Thesaurus available due to this OWLOntologyStorageException on save. I'd be interested to try upgrading to whichever release number contains this fix. Thanks!
|
There's no timeline planned but I don't see obstacles to a patch release within days - possibly tomorrow. |
Great! Thanks so much! |
4.2.1 has been released |
Should resolve NCIT save exceptions per owlcs/owlapi#495.
OWl API 4.1.3 loads the attached file (see below) just fine. The file contains an XML Literal as the value of an annotation property:
However, when trying to save the ontology, OWL API throws the exception shown below. (The exception is generated by Protege 5.0.0-b23, but it can also be reproduced just with the OWL API)
OWL API 3.5.1 loads and saves this file with no error.
File that shows the behavior: textXmlLiteral_5.owl.zip
If the syntax is valid (I believe it is), then the OWL API should load and save the file successfully. If the syntax is invalid, I would expect to see an error at load time.
Related to #412 and #439.
Exception when trying to save the file:
The text was updated successfully, but these errors were encountered: