windows installer: docs should use / in urls, not \
split up from #4292 (closed), as requested. Description there was:
Documentation cross-links are thoroughly messed up (the urls seem to be missing the package identifier): eg, the Bool in Data.List refer to libraries/Data-Bool.. instead of libraries/base-4.2.0.2%5CData-Bool..
To reproduce (in Opera 10.61):
- open Haskell hierarchical libraries HTML documentation (eg, via the startup menu group GHC)
- navigate to
Data.List
page - scroll down to
null
entry - click on
Bool
in type signature - notice error message (file not found)
From looking at the directory structure, it is obvious that there should be a further indirection in the url, namely the package identifier:
base-4.3.0.0
Step 5 leaves Opera with this url
file://localhost/C:/haskell/ghc/ghc-7.0.0.20100925/doc/html/libraries/Data-Bool.html#t:Bool
instead of the correct
file://localhost/C:/haskell/ghc/ghc-7.0.0.20100925/doc/html/libraries/base-4.3.0.0/Data-Bool.html#t:Bool
On closer inspection, that id is present in the Data-List.html
url, and the link to Data-Bool.html
is relative, in the same package/directory.
Unfortunately, the Data-List.html
url itself (from libraries/index.html
), uses \
instead of the last /
, which Opera encodes as %5C
, which causes the relative link to Data-Bool.html
to fail (missing package id, which would have been the last path component, which does not get recognized due to missing /
).
Other browsers may behave differently, but my reading of rfc3986
is that \
does not separate hierarchical url components, hence there is no guarantee that relative links will work as used here (though, as so often, there is room for interpretation).
Replacing the %5C
with a /
and reloading Data-List.html
is sufficient to make the links to Data-Bool.html
et al work as expected, so the fix would be to get rid of spurious \
s in hrefs in the docs, especially in libraries/index.html
.
Trac metadata
Trac field | Value |
---|---|
Version | 6.12.3 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Documentation |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | |
Architecture |