I understand from your description that I can work around this by
avoiding relative prefixes.
I replaced instances of : with <#> and removed the prefix and it seems
to work now.

On Mon, Dec 9, 2013 at 10:45 AM, Andy Seaborne <[email protected]> wrote:
> Recorded:
>
> https://issues.apache.org/jira/browse/JENA-606
>
>
> On 08/12/13 23:08, Martynas Jusevičius wrote:
>>
>> Hey,
>>
>> I've upgraded to Jena 2.11.0 as part of SPIN API 1.3.1. As a result,
>> previously working RDF/XML output breaks:
>>
>> com.hp.hpl.jena.shared.BadURIException: Only well-formed absolute
>> URIrefs can be included in RDF/XML output: <#> Code:
>> 57/REQUIRED_COMPONENT_MISSING in SCHEME: A component that is required
>> by the scheme is missing.
>>
>> com.hp.hpl.jena.xmloutput.impl.BaseXMLWriter.checkURI(BaseXMLWriter.java:820)
>>
>> com.hp.hpl.jena.xmloutput.impl.BaseXMLWriter.xmlnsDecl(BaseXMLWriter.java:339)
>> com.hp.hpl.jena.xmloutput.impl.Basic.writeRDFHeader(Basic.java:64)
>> com.hp.hpl.jena.xmloutput.impl.Basic.writeBody(Basic.java:47)
>>
>> com.hp.hpl.jena.xmloutput.impl.BaseXMLWriter.writeXMLBody(BaseXMLWriter.java:492)
>> com.hp.hpl.jena.xmloutput.impl.BaseXMLWriter.write(BaseXMLWriter.java:464)
>> com.hp.hpl.jena.xmloutput.impl.BaseXMLWriter.write(BaseXMLWriter.java:450)
>> com.hp.hpl.jena.rdf.model.impl.ModelCom.write(ModelCom.java:333)
>>
>> org.graphity.processor.provider.OntologyProvider.getOntModel(OntologyProvider.java:122)
>>
>> I really hope I can work around this as I spent the whole weekend
>> upgrading to 2.11.0 :/
>> This seems to be related to relative URIs of the form <#>. Attached is
>> the code to reproduce the issue:
>>
>>          Model test = ModelFactory.createDefaultModel();
>>          test.read("jena-test.ttl");
>>          test.write(System.out, "RDF/XML");
>>
>> jena-test.ttl content:
>>
>> @base           <http://localhost:8080/graphity-client/> .
>> @prefix : <#> .
>> @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
>>
>> <.> rdfs:isDefinedBy : .
>>
>>
>> Martynas
>> graphityhq.com
>>
>

Reply via email to