rules_haskell
rules_haskell copied to clipboard
There are files missing in the package / ghc-pkg check error
After upgrading to the latest commit (from v0.14) I receive numerous errors of the following form:
Use --sandbox_debug to see verbose messages from the sandbox
Control/Concurrent/Async.hs:217:1: error:
Could not find module ‘Data.Hashable’
There are files missing in the ‘hashable-1.4.0.2’ package,
try running 'ghc-pkg check'.
Use -v (or `:set -v` in ghci) to see a list of the files searched for.
|
217 | import Data.Hashable (Hashable(hashWithSalt))
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Numerous other libraries like divisible
and contravariant
all fail with the same error(s). The stack_snapshot's stackage/BUILD.bazel
entries look fine, as do the source directories themselves (ie. containing the correct files/structure.)
haskell_cabal_library(
name = "hashable",
version = "1.4.0.2",
haddock = False,
flags = [],
srcs = glob(["hashable-1.4.0.2/**"]),
deps = ["base", "bytestring", "containers", "deepseq", "ghc-bignum", "ghc-prim", "text"],
setup_deps = [],
tools = ["@nixpkgs_alex//:bin/alex", "@nixpkgs_c2hs//:bin/c2hs", "@nixpkgs_happy//:bin/happy"],
visibility = ["//visibility:public"],
cabalopts = ["--ghc-option=-w", "--ghc-option=-optF=-w"],
verbose = False,
unique_name = True,
)
Is this an error someone else has run into previously? Manually writing a BUILD file and vendoring in the stack_snapshot etc. works, even with the exact content above.