haskell / haskell/hackage-server

Missing hyperlinks to types and functions in external packages (Haddock on Hackage).

Open
#1,364 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Haskell
Stars
467
Forks
225
PR merge metrics
No merged PRs in 30d

Description

When Hackage generates Haddock documentation for [`monoidmap-aeson`](https://hackage.haskell.org/package/monoidmap-aeson-0.0.0.2/docs/Data-MonoidMap-JSON.html), it:
- successfully generates hyperlinks to types and functions in packages such as [`aeson`](https://hackage.haskell.org/package/aeson) and [`monoid-subclasses`](https://hackage.haskell.org/package/monoid-subclasses).
- but fails to generate hyperlinks to types and functions from the [`monoidmap`](https://hackage.haskell.org/package/monoidmap) package.

## Logs and debugging

Is it possible to inspect logs for haddock generation on hackage? I can see logs [here](https://hackage.haskell.org/package/monoidmap-aeson-0.0.0.2/reports/1), but can't see an obvious cause for the hyperlink failure. (Though perhaps I'm looking in the wrong place?)

## Versions

This has happened for all of the following versions:
- [`monoidmap-aeson-0.0.0.0`](https://hackage.haskell.org/package/monoidmap-aeson-0.0.0.0/docs/Data-MonoidMap-JSON.html)
- [`monoidmap-aeson-0.0.0.1`](https://hackage.haskell.org/package/monoidmap-aeson-0.0.0.1/docs/Data-MonoidMap-JSON.html)
- [`monoidmap-aeson-0.0.0.2`](https://hackage.haskell.org/package/monoidmap-aeson-0.0.0.2/docs/Data-MonoidMap-JSON.html)
- [`monoidmap-aeson-0.0.0.3`](https://hackage.haskell.org/package/monoidmap-aeson-0.0.0.3/docs/Data-MonoidMap-JSON.html)

I initially assumed that there must be something broken in the `monoidmap-aeson` package.

However, when I run `cabal haddock` locally on the same source code, or as part of CI (which uses Haddock version 2.30.0), everything works as expected, and all hyperlinks are generated successfully. 🤷🏻

## Expected behaviour

Documentation built by GitHub actions ([link](http://jonathanknowles.net/monoidmap-aeson/Data-MonoidMap-JSON.html)) (Haddock version 2.30.0):

![Image](https://github.com/user-attachments/assets/14bb709e-1a55-45df-b4b2-16a81f476284)

Note that symbols like `MonoidMap` and `fromList` are successfully hyperlinked.

## Actual behaviour

Documentation built on Hackage ([link](https://hackage.haskell.org/package/monoidmap-aeson-0.0.0.2/docs/Data-MonoidMap-JSON.html)):

![Image](https://github.com/user-attachments/assets/ed71fa0b-6801-46d9-948b-16d0347324da)

Note that symbols like `ToJSON`, `encode`, and `Sum` are hyperlinked, but `MonoidMap` and `fromList` are **not**, and yet both of these are exported from the `Data.MonoidMap` module, as already published on hackage (see [`monoidmap:Data.MonoidMap`](https://hackage.haskell.org/package/monoidmap-0.0.3.0/docs/Data-MonoidMap.html)).

## Workarounds

I know it's possible to upload documentation manually, but I'd like to figure out if there's something I'm doing wrong that is preventing Hackage from successfully generating hyperlinks to `monoidmap`.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.