Hadrian chews up Haddock's error message
Here's the error I'm getting with make
:
Preprocessing library for ghc-prim-0.6.1..
"/builds/ghc/ghc/inplace/bin/haddock" --verbosity=0 --odir="libraries/ghc-prim/dist-install/doc/html/ghc-prim" --no-tmp-comp-dir --dump-interface=libraries/ghc-prim/dist-install/doc/html/ghc-prim/ghc-prim.haddock --html --hoogle --quickjump --title="ghc-prim-0.6.1: GHC primitives" --prologue="libraries/ghc-prim/dist-install/haddock-prologue.txt" --optghc="-D__HADDOCK_VERSION__=2220" --optghc=-hisuf --optghc=dyn_hi --optghc=-osuf --optghc=dyn_o --optghc=-hcsuf --optghc=dyn_hc --optghc=-fPIC --optghc=-dynamic --optghc=-O --optghc=-H64m --optghc=-Wall --optghc=-Werror --optghc=-this-unit-id --optghc=ghc-prim-0.6.1 --optghc=-hide-all-packages --optghc=-i --optghc=-ilibraries/ghc-prim/. --optghc=-ilibraries/ghc-prim/dist-install/build --optghc=-Ilibraries/ghc-prim/dist-install/build --optghc=-ilibraries/ghc-prim/dist-install/build/./autogen --optghc=-Ilibraries/ghc-prim/dist-install/build/./autogen --optghc=-Ilibraries/ghc-prim/. --optghc=-optP-include --optghc=-optPlibraries/ghc-prim/dist-install/build/./autogen/cabal_macros.h --optghc=-package-id --optghc=rts --optghc=-this-unit-id --optghc=ghc-prim --optghc=-XHaskell2010 --optghc=-O2 --optghc=-g3 --optghc=-haddock --optghc=-no-user-package-db --optghc=-rtsopts --optghc=-Wno-trustworthy-safe --optghc=-Wno-deprecated-flags --optghc=-Wnoncanonical-monad-instances --optghc=-outputdir --optghc=libraries/ghc-prim/dist-install/build --source-module=src/%{MODULE/./-}.html --source-entity=src/%{MODULE/./-}.html#%{NAME} libraries/ghc-prim/./GHC/CString.hs libraries/ghc-prim/./GHC/Classes.hs libraries/ghc-prim/./GHC/Debug.hs libraries/ghc-prim/./GHC/IntWord64.hs libraries/ghc-prim/./GHC/Magic.hs libraries/ghc-prim/./GHC/Prim/Ext.hs libraries/ghc-prim/dist-install/build/GHC/PrimopWrappers.hs libraries/ghc-prim/./GHC/Tuple.hs libraries/ghc-prim/./GHC/Types.hs libraries/ghc-prim/dist-install/build/autogen/GHC/Prim.hs +RTS -t"/builds/ghc/ghc/testsuite/tests/perf/haddock/ghc-prim.t" --machine-readable
Warning: Couldn't find .haddock for export TYPE
haddock: internal error: No match in record selector tyConTyVars
make[1]: *** [libraries/ghc-prim/dist-install/doc/html/ghc-prim/ghc-prim.haddock] Error 1
make[1]: *** Waiting for unfinished jobs....
libraries/ghc-prim/ghc.mk:4: recipe for target 'libraries/ghc-prim/dist-install/doc/html/ghc-prim/ghc-prim.haddock' failed
Makefile:123: recipe for target 'all' failed
make: *** [all] Error 2
The line of interest for me is this:
haddock: internal error: No match in record selector tyConTyVars
Alas, it's missing in Hadrian output:
| Run Haddock BuildPackage: libraries/ghc-prim/GHC/CString.hs (and 9 more) => _build/docs/html/libraries/ghc-prim/ghc-prim.haddock
Error when running Shake build system:
at want, called at src/Main.hs:89:30 in main:Main
* Depends on: binary-dist
at apply1, called at src/Development/Shake/Internal/Rules/Rerun.hs:41:5 in shake-0.18.3-fe164878506ea9c53ac2471854e5a28736bfe5298687d30e443a846a8b6228c2:Development.Shake.Internal.Rules.Rerun
* Depends on: binary-dist-dir
at need, called at src/Rules/BinaryDist.hs:123:9 in main:Rules.BinaryDist
* Depends on: docs
at need, called at src/Rules/Documentation.hs:107:9 in main:Rules.Documentation
* Depends on: _build/docs/archives/libraries.html.tar.xz
at need, called at src/Rules/Documentation.hs:272:9 in main:Rules.Documentation
* Depends on: _build/docs/html/libraries/index.html
at need, called at src/Rules/Documentation.hs:164:9 in main:Rules.Documentation
* Depends on: _build/docs/html/libraries/ghc-prim/ghc-prim.haddock
* Raised the exception:
user error (Development.Shake.cmd, system command failed
Command line: _build/stage1/bin/haddock --verbosity=0 -B_build/stage1/lib --lib=_build/stage1/lib --odir=_build/docs/html/libraries/ghc-prim --no-tmp-comp-dir --dump-interface=_build/docs/html/libraries/ghc-prim/ghc-prim.haddock --html --hyperlinked-source --hoogle --quickjump '--title=ghc-prim-0.6.1: GHC primitives' --prologue=_build/docs/html/libraries/ghc-prim/haddock-prologue.txt --optghc=-D__HADDOCK_VERSION__=2220 --optghc=-hisuf --optghc=dyn_hi --optghc=-osuf --optghc=dyn_o --optghc=-hcsuf --optghc=dyn_hc --optghc=-fPIC --optghc=-dynamic --optghc=-hide-all-packages --optghc=-no-user-package-db '--optghc=-this-unit-id ghc-prim-0.6.1' '--optghc=-package-id rts-1.0' --optghc=-i --optghc=-i_build/stage1/libraries/ghc-prim/build --optghc=-i_build/stage1/libraries/ghc-prim/build/autogen --optghc=-ilibraries/ghc-prim/. --optghc=-Iincludes --optghc=-I_build/generated --optghc=-I_build/stage1/libraries/ghc-prim/build --optghc=-I/builds/ghc/ghc/_build/stage1/lib/x86_64-linux-ghc-8.9.0.20190907/rts-1.0/include --optghc=-I_build/generated --optghc=-optc-I_build/generated --optghc=-optP-include --optghc=-optP_build/stage1/libraries/ghc-prim/build/autogen/cabal_macros.h --optghc=-outputdir --optghc=_build/stage1/libraries/ghc-prim/build --optghc=-this-unit-id --optghc=ghc-prim --optghc=-XHaskell2010 --optghc=-ghcversion-file=/builds/ghc/ghc/_build/generated/ghcversion.h --optghc=-Wno-deprecated-flags --optghc=-Wno-trustworthy-safe libraries/ghc-prim/GHC/CString.hs libraries/ghc-prim/GHC/Classes.hs libraries/ghc-prim/GHC/Debug.hs libraries/ghc-prim/GHC/IntWord64.hs libraries/ghc-prim/GHC/Magic.hs libraries/ghc-prim/GHC/Prim/Ext.hs _build/stage1/libraries/ghc-prim/build/GHC/PrimopWrappers.hs libraries/ghc-prim/GHC/Tuple.hs libraries/ghc-prim/GHC/Types.hs _build/stage1/libraries/ghc-prim/build/GHC/Prim.hs +RTS -t_build/stage1/haddock-timing-files/ghc-prim.t --machine-readable -RTS
Exit code: 1
Stderr:
)
I don't know how I would debug this if not for the make
output from CI.
Steps to reproduce:
git checkout 8e8ddde1973759a1a04190306e8280f322dd20ac
hadrian/build.sh -j --flavour=Quick docs-haddock