commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <>
Subject [jira] [Commented] (COMMONSRDF-55) Stream of Jena quads use wrong IRI for default graph
Date Wed, 01 Feb 2017 15:07:51 GMT


ASF GitHub Bot commented on COMMONSRDF-55:

Github user stain commented on the issue:
    Any comments from perhaps @afs or @ajs6f? I'm not sure exactly at what boundary we should
replace `<urn:x-arq:DefaultGraph>` and friends with `Optional.empty()` -- in the solution
of this PR it happens for any Quad created with `JenaRDF` - but of course that would not happen
in other `RDF` instances. This suggestion would also convert any "foreign" `IRI` instances
of `<urn:x-arq:DefaultGraph>` when given as a graph name.
    I'll admit there's potential for information loss if the alternate  `<urn:x-arq:DefaultGraphNode>`
is used as a string IRI or Node when making a Commons RDF Quad  - this PR will adapt it into
`<urn:x-arq:DefaultGraph> when later making the Jena `Quad` instance from the field
of Optional.empty(), however Jena's `DatasetGraph` also does that conversion.

> Stream of Jena quads use wrong IRI for default graph
> ----------------------------------------------------
>                 Key: COMMONSRDF-55
>                 URL:
>             Project: Apache Commons RDF
>          Issue Type: Bug
>          Components: jena
>    Affects Versions: 0.3.0
>            Reporter: Stian Soiland-Reyes
>            Assignee: Stian Soiland-Reyes
>             Fix For: 1.0.0
> See
> {code}
> org.apache.commons.rdf.jena.DatasetJenaTest
> streamLanguageTagsCaseInsensitive(org.apache.commons.rdf.jena.DatasetJenaTest)  Time
elapsed: 0.012 sec  <<< FAILURE!
> java.lang.AssertionError: expected:<<> <>
"Hello"@EN-GB <urn:x-arq:DefaultGraph>.> but was:<<>
<> "Hello"@en-GB .>
> {code}
> Jena uses the IRI `<urn:x-arq:DefaultGraph>` internally to represent the default
graph within datasets - we need to recognize that on the way out of a ``
and possibly in the `asQuad(JenaQuad)` converter and replace it with `Optional.empty()` so
the default graph appears the same across implementations.
> The `AbstractDatasetTest`  should be augmented to do more tests on the default graph,
including `.stream()`, `.iterate()`, `.contains()` and `.remove()`1.

This message was sent by Atlassian JIRA

View raw message