Open filterfish opened 4 years ago
What does the doc
folder contain within it? Are CHANGES.txt and hoogle.txt at the same level of the directory hierarchy. I don't really use local generation of Hoogle databases, so don't have much opinion on what the right way to do it is - it needs someone to figure out the use case, and then make it work.
Yeah the CHANGES.txt
file is in share/doc/html
. I would argue, certainly in the short term, that CHANGES.txt
shouldn't be in share/doc/html
, it should be one level up with LICENSE
.
In the longer term can hoogle simply read the text file named after the package name. I've just checked every package installed on my machine and they all conform to that pattern though the number of packages on my machine is a small sample compared to every package on hackage.
This could also be addressed by changing the hard-fail on https://github.com/ndmitchell/hoogle/blob/master/src/Input/Haddock.hs#L89 to a log message. That may be the easiest fix.
Sorry that the title sounds like a tabloid newspaper headline but I couldn't think of anything else!
If I run the following command
hoogle fails with the following:
This confused me at first because I thought I needed use "embed" mode but it turns out that if I remove the CHANGES.txt file from the directory it works properly. So after a bit of digging I narrowed it down to a single line in that file: line 269 (commit #4bd66888 which is the current master). The offending line is:
I see on #355 you mention that the method you use to search for
.txt
files is not very robust but do you have any thoughts about how best to handle this in the long term?