Re: RDF's relative IRI resolution is ambiguous

> On Sep 3, 2015, at 11:50 AM, Ruben Verborgh <ruben.verborgh@ugent.be> wrote:
> 
>> As I read RFC3986, the trailing .. in the base disappears in the merging of the base and relative URIs (§5.2.3), before remove_dot_segments() is invoked.
> 
> That's indeed what the RFC says, and if we follow it literally, this is what we must do.
> I just can't imagine this is what the RFC actually intended, since ".." is a special path.

Both of the Ruby URI implementations (built-in and Addressable) remove the dot segments, as does my own implementation. However, the spec is clear, and it seems that I’ve been doing this wrong, too.

This implies that we should accept Greg’s reasoning on the tests, but perhaps add <http://a/bb/ccc/../> and <http://a/bb/ccc/./> cases to be sure. Right now, there should be no difference between <http://a/bb/ccc/> <http://a/bb/ccc/.>, <http://a/bb/ccc/..>, or <http://a/bb/ccc/d>

Unfortunately, making this change does seem to break a bunch of stuff, and right now it’s hard to know how much of it is localized to my implementation, and how much of it may ripple into something like JSON-LD (e.g., http://json-ld.org/test-suite/tests/expand-0029-in.jsonld). We need to tread lightly, and get broader input across other implementations of different related specs.

Gregg

> Ruben

Received on Thursday, 3 September 2015 19:44:48 UTC