BuildClient: docs uploads for multi-library packages are rejected by checkDocTarball; switch to `cabal haddock --haddock-for-hackage`
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 55/100
- Tipo de issue
- Error
- Claridad
- Bien especificado
- Estado de actividad
- Activo
- Stack tecnológico
- haskell
- Área
- build-system, documentation
Línea de trabajo
Start in exes/BuildClient.hs at buildPackage, then compare the v2-test project flow and checkDocTarball validation. Run the documentation-builder tests with a multi-library package such as happy-lib or hackage-cli, using a toolchain containing GHC MR !16706. Done means the generated tarball passes validation while preserving reports, logs, pruning, and dry-run behavior; note the re-export-only limitation.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Hackage's documentation builder (exes/BuildClient.hs) cannot publish documentation for any package with sub-libraries. The v1-based docs build does generate the haddocks of all the libraries of a package, but the hand-packed tarball contains the Hoogle description files haddock writes for sub-libraries, named <pkg>:<sublib>.txt (GHC MR !16706). Since the stricter upload validation was deployed, checkDocTarball rejects these tarballs:
Invalid windows file name in tar archive:
"happy-lib-2.0-docs\\backend-glr\\happy-lib:backend-glr.txt"
So for packages like haskell-debugger (dap-server), happy-lib (five internal libraries) or hackage-cli (cabal-revisions), Hackage ends up with no documentation at all. See haskell/cabal#10973 (first report of the rejected upload) and haskell/cabal#12364.
It might be worth solving the problem this way https://github.com/haskell/hackage-server/pull/1522
buildPackage now runs the current v2 flow in the unpacked package's project (the same project v2-test already uses):
cabal haddock all --haddock-for-hackage --build-summary=<results>/<pkgid>.report
and uploads the tarball cabal produces, instead of hand-packing the htmldir tree. --haddock-for-hackage bakes in the same hosting URLs the client used to pass explicitly (/package/$pkg-$version(/docs)), and implies html, hoogle, hyperlinked source and quickjump. Build reports (install-outcome gating for the test step), logs, --prune-haddock-files (unpack → prune → repack) and --dry-run are preserved.
Requirements: the builder's toolchain must ship the haddock fix from GHC MR !16706 (with an older haddock, checkDocTarball rejects the builder's own uploads for multi-library packages — that is the status quo).
Known limitation
Libraries whose only modules are re-exports are currently not haddocked by the v2 flow (cabal's hasValidHaddockTargets gate; see haskell/cabal#10368), so for such packages the tarball has no root index.html. All sub-library haddocks are present and the tarball passes validation — strictly better than the status quo, but the cabal-side gate should ideally be relaxed too.
- Lenguaje dominante
- Haskell
- Estrellas
- 471
- Forks
- 228
- Merge medio
- 5 d 6 h
- PR fusionados (30 d)
- 3
Preparar el entorno
- Incluye un Dockerfile o un archivo de Docker Compose
- Sin plantilla de pull request
- Sin guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de haskell/hackage-server
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 22/100
haskell/hackage-server#1530 · 4 comentarios · 2 reacciones ·
-
Dificultad 4/5 3-5 días Aptitud para principiantes 45/100
haskell/hackage-server#1528 · 1 comentario ·
-
Count downloads from content delivery networkPosiblemente ocupada @LaurentRDC la tomó hace 60 días. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 55/100
haskell/hackage-server#1517 · 1 comentario ·
-
hackage-mirror can't mirror old packagesPosiblemente ocupada @TTyChud la tomó hace 7 días. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 40/100
haskell/hackage-server#1515 ·
-
Dificultad 4/5 3-5 días Aptitud para principiantes 42/100
haskell/hackage-server#1503 ·
Todos los issues de haskell/hackage-server
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
haskell/bytestring#730 · 1 comentario ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
seal-harness/seal-harness#399 ·
Los mantenedores suelen responder en 1 día
-
add previously overlooked rulesAbiertobug
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
fmidue/codeworld-tasks#124 ·
-
allow haskell-src-exts-1.24Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
reflex-frp/reflex#563 ·