Closed
Description
Describe the bug
Accidentally, I've discovered that stack_snapshot packages list may contain "quasi-duplicates".
To Reproduce
Put two packages to stack_snapshot::packages
where one is taken from stack snapshot and the other one contains a strict version, e.g:
stack_snapshot(
packages = [
...
"wai-make-assets",
"wai-make-assets-0.2",
...
]
)
Expected behavior
While, in duplicated such case, using reference without the version is allowed for targets of type e.g. haskell_library
:
haskell_library(
deps = [
"@stackage//:wai-make-asstets",
],
)
rules_haskell should probably generate an error. For a reader it may be a bit misleading what's happening in such case. Does the dependency come from stackage or hackage (https://rules-haskell.readthedocs.io/en/latest/haskell-use-cases.html#version-overrides-or-hackage-dependencies)?
Environment
- OS name + version: Nixos 22.05.2351.e4c9d950a3c
- Bazel version: bazel 4.1.0-
- Version of the rules: "rules_haskell-0.14"
Additional context
tweag/gazelle_cabal#46