The fetched packages are behind the commit that https://ghc.gitlab.haskell.org/head.hackage/ displays
The contents of the packages I get from head.hackage does not match the patches at the commit advertised at https://ghc.gitlab.haskell.org/head.hackage/
I can generate a smaller repro, but the situation where I encountered that is the following: the commit is said to be 9783eac1, which means that ghc-typelits-natnormalise-0.7.9 should have template haskell patched in. But it does not. When I do
git clone git@github.com:mpickering/crispy-computing-machine.git
cd crispy-computing-machine
cabal build --allow-newer --enable-optimization --ghc-options='-dcore-lint -dstg-lint -dcmm-lint -dtag-inference-checks' -w /home/mikolaj/r/ghc.HEAD/ghc/_build/stage1/bin/ghc -ftest_seq --ghc-options="-fpolymorphic-specialisation"
it should compile, but it fails as follows
~/r/crispy-computing-machine$ cabal build --allow-newer --enable-optimization --ghc-options='-dcore-lint -dstg-lint -dcmm-lint -dtag-inference-checks' -w /home/mikolaj/r/ghc.HEAD/ghc/_build/stage1/bin/ghc -ftest_seq --ghc-options="-fpolymorphic-specialisation"
Resolving dependencies...
Warning: Fetched tarball
/home/mikolaj/.cabal/packages/head.hackage.ghc.haskell.org/ghc-tcplugins-extra/0.4.5/ghc-tcplugins-extra-0.4.5.tar.gz
does not match server, will redownload: file length mismatch
Warning: Fetched tarball
/home/mikolaj/.cabal/packages/head.hackage.ghc.haskell.org/ghc-typelits-knownnat/0.7.10/ghc-typelits-knownnat-0.7.10.tar.gz
does not match server, will redownload: file length mismatch
Warning: Fetched tarball
/home/mikolaj/.cabal/packages/head.hackage.ghc.haskell.org/ghc-typelits-natnormalise/0.7.9/ghc-typelits-natnormalise-0.7.9.tar.gz
does not match server, will redownload: file length mismatch
Build profile: -w ghc-9.11.20240412 -O1
In order, the following will be built (use -v for more details):
- ghc-tcplugins-extra-0.4.5 (lib) (requires build)
- ghc-typelits-natnormalise-0.7.9 (lib) (requires build)
- ghc-typelits-knownnat-0.7.10 (lib) (requires build)
- repro-0.1.0.0 (exe:repro) (first run)
Starting ghc-tcplugins-extra-0.4.5 (lib)
Building ghc-tcplugins-extra-0.4.5 (lib)
Installing ghc-tcplugins-extra-0.4.5 (lib)
Completed ghc-tcplugins-extra-0.4.5 (lib)
Starting ghc-typelits-natnormalise-0.7.9 (lib)
Building ghc-typelits-natnormalise-0.7.9 (lib)
Installing ghc-typelits-natnormalise-0.7.9 (lib)
Completed ghc-typelits-natnormalise-0.7.9 (lib)
Starting ghc-typelits-knownnat-0.7.10 (lib)
Building ghc-typelits-knownnat-0.7.10 (lib)
Installing ghc-typelits-knownnat-0.7.10 (lib)
Completed ghc-typelits-knownnat-0.7.10 (lib)
Configuring executable 'repro' for repro-0.1.0.0...
Preprocessing executable 'repro' for repro-0.1.0.0...
Building executable 'repro' for repro-0.1.0.0...
[1 of 4] Compiling SizedIndex ( SizedIndex.hs, /home/mikolaj/r/crispy-computing-machine/dist-newstyle/build/x86_64-linux/ghc-9.11.20240412/repro-0.1.0.0/x/repro/build/repro/repro-tmp/SizedIndex.o )
SizedIndex.hs:1:1: error: []8;;https://errors.haskell.org/messages/GHC-83249\GHC-83249]8;;\]
Can't find interface-file declaration for type constructor or class Data.Type.Ord.OrdCond
Probable cause: bug in .hi-boot file, or inconsistent .hi file
Use -ddump-if-trace to get an idea of which file caused the error
|
1 | {-# LANGUAGE DerivingStrategies, ViewPatterns, AllowAmbiguousTypes, RankNTypes #-}
| ^
which is consistent with the bug the commit should have fixed in !366 (merged) and, indeed, when I inspect the contents of /home/mikolaj/.cabal/packages/head.hackage.ghc.haskell.org/ghc-typelits-natnormalise/0.7.9/ghc-typelits-natnormalise-0.7.9.tar.gz, it does not have the changes that introduce template haskell. It's the same with /home/mikolaj/.cabal/packages/head.hackage.ghc.haskell.org/ghc-typelits-knownnat/0.7.10/ghc-typelits-knownnat-0.7.10.tar.gz.
BTW, what's that "file length mismatch" warning? I'm seeing it a lot.