dajobe / raptor

Redland Raptor RDF syntax library
https://librdf.org/raptor/
Other
156 stars 62 forks source link

Casing of domain name and scheme should be canonicalized (and interpreted as such) #62

Closed athalhammer closed 1 year ago

athalhammer commented 1 year ago

Not sure if I interpret rfc3986 correctly but I believe that with input file:

<https://example.com> <https://ex.com> <https://EXAMPLE.COM> .
<https://example.com> <HTTPS://ex.com> <https://eXAMPLE.COM> .

... and command:

$ rapper --input turtle input.ttl --output turtle
rapper: Serializing with serializer turtle
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .

<https://example.com>
    <HTTPS://ex.com> <https://eXAMPLE.COM> ;
    <https://ex.com> <https://EXAMPLE.COM> .
rapper: Parsing returned 2 triples

... the output should be the same output as with the follwoing input:

<https://example.com> <https://ex.com> <https://example.com> .
<https://example.com> <https://ex.com> <https://example.com> .

... which is:

rapper: Serializing with serializer turtle
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .

<https://example.com>
    <https://ex.com> <https://example.com> .

rapper: Parsing returned 2 triples
athalhammer commented 1 year ago

Okay, I found https://www.w3.org/TR/rdf11-concepts/#section-IRIs where it is clearly stated:

IRI equality: Two IRIs are equal if and only if they are equivalent under Simple String Comparison according to section 5.1 of [RFC3987]. Further normalization MUST NOT be performed when comparing IRIs for equality.

which basically means we can close this issue. Sorry for the hassle.

dajobe commented 12 months ago

Hi, catching up. That stuff is in unit tests so I would have been very surprised if it was broken.