A few issues with ZnUrl>>withRelativeReference:
kasperosterbye opened this issue · 4 comments
In rfc3986 section 5.4.1 and 5.4.2 there is a number of tests cases.
I implemented them in the attached file - there is a very few that do not pass. Just wanted to pass it on, I did not want to do a fork and a PR for this. It is a classic fileout.
Did you see my comment in pharo-project/pharo#10328 in full ?
Did you see ZnUrlTest>>#testReferenceResolution ?
I think this was already done ;-)
I bow in the ashes for the great master!
Awesome!
The resolution is needed for relative url resolution in microdown for images, links and inputfiles. I would like to reuse the functionality present in ZnUrl (which now seems both possible and attractive). In particular I like that the resolution works for both file and http(s).
Though unrelated to this issue I was wondering if you had any ideas for how to support the Memory filesystem. I was thinking about file://memory/path, but as one creates stores on the fly it becomes an issue which memory store is meant. Have you had any thought on that?
I was thinking of introducing naming scheme and a (weak) hash map, allowing file://foo.memory/path, which would be resolvable if one had registred a memory store under the name foo in some other way.
Thx.
I am not very familiar with the memory file system, from what I hear it is mostly used for tests.
If anything, my first idea would be to use a new scheme, maybe mfile:// and use the host as identifier,
mfile://foo/path
But maybe memory-file:// would even be better.
memory-file://foo/path
I use such URLs as connection specifications for various protocols.
Tx. Those are a good ideas too.