Skip to content

cabal install fails due to missing AnyVersion, WildcardVersion, ... #5

@scarf005

Description

@scarf005

Summary

cabal install cabal-edit fails with missing identifiers

Haskell info

(fetched using ghcup tui)

GHC 9.0.2
cabal 3.8.1.0

Build Log

Details
❯ cabal install cabal-edit
Resolving dependencies...
Build profile: -w ghc-9.0.2 -O1
In order, the following will be built (use -v for more details):
 - cabal-edit-0.1.0.0 (exe:cabal-edit) (requires build)
Starting     cabal-edit-0.1.0.0 (exe:cabal-edit)
Building     cabal-edit-0.1.0.0 (exe:cabal-edit)

Failed to build exe:cabal-edit from cabal-edit-0.1.0.0.
Build log (
/home/scarf/.cabal/logs/ghc-9.0.2/cabal-edit-0.1.0.0-e-cabal-edit-72fad4d31d4f26d321ac6d7854c9e7b56681fc85aac1b3221636deb58a1b5514.log
):
Configuring executable 'cabal-edit' for cabal-edit-0.1.0.0..
Preprocessing executable 'cabal-edit' for cabal-edit-0.1.0.0..
Building executable 'cabal-edit' for cabal-edit-0.1.0.0..
[1 of 1] Compiling Main ( exe/Main.hs, dist/build/cabal-edit/cabal-edit-tmp/Main.o )

exe/Main.hs:146:5: error:
Not in scope: data constructor ‘AnyVersion’
Perhaps you meant one of these:
variable ‘anyVersion’ (imported from Distribution.Types.VersionRange.Internal),
variable ‘noVersion’ (imported from Distribution.Types.VersionRange.Internal),
variable ‘mkVersion’ (imported from Distribution.Types.Version)
|
146 | AnyVersion -> do
| ^^^^^^^^^^

exe/Main.hs:160:5: error:
Not in scope: data constructor ‘WildcardVersion’
|
160 | WildcardVersion givenVersion -> addVer WildcardVersion givenVersion (fname, cabalFile) dep
| ^^^^^^^^^^^^^^^

exe/Main.hs:188:9: error:
Not in scope: data constructor ‘AnyVersion’
Perhaps you meant one of these:
variable ‘anyVersion’ (imported from Distribution.Types.VersionRange.Internal),
variable ‘noVersion’ (imported from Distribution.Types.VersionRange.Internal),
variable ‘mkVersion’ (imported from Distribution.Types.Version)
|
188 | AnyVersion -> replaceVersion dep
| ^^^^^^^^^^

exe/Main.hs:189:9: error:
Not in scope: data constructor ‘WildcardVersion’
|
189 | WildcardVersion _ -> replaceVersion dep
| ^^^^^^^^^^^^^^^

exe/Main.hs:193:9: error:
Not in scope: data constructor ‘VersionRangeParens’
Perhaps you meant variable ‘versionRangeParser’ (imported from Distribution.Types.VersionRange.Internal)
|
193 | VersionRangeParens _ -> replaceVersion dep
| ^^^^^^^^^^^^^^^^^^

exe/Main.hs:296:5: error:
Not in scope: data constructor ‘AnyVersion’
Perhaps you meant one of these:
variable ‘anyVersion’ (imported from Distribution.Types.VersionRange.Internal),
variable ‘noVersion’ (imported from Distribution.Types.VersionRange.Internal),
variable ‘mkVersion’ (imported from Distribution.Types.Version)
|
296 | AnyVersion -> putStrLn $ prettyShow pk ++ " : " ++ "Wildcard version detected. Instead use explicit version bounds."
| ^^^^^^^^^^

exe/Main.hs:308:5: error:
Not in scope: data constructor ‘WildcardVersion’
|
308 | WildcardVersion ver ->
| ^^^^^^^^^^^^^^^

exe/Main.hs:324:5: error:
Not in scope: data constructor ‘VersionRangeParens’
Perhaps you meant variable ‘versionRangeParser’ (imported from Distribution.Types.VersionRange.Internal)
|
324 | VersionRangeParens _ -> pure ()
| ^^^^^^^^^^^^^^^^^^
Error: cabal: Failed to build exe:cabal-edit from cabal-edit-0.1.0.0. See the
build log above for details.

System info

Details
Operating System: Kubuntu 22.04
KDE Plasma Version: 5.24.6
KDE Frameworks Version: 5.95.0
Qt Version: 5.15.3
Kernel Version: 5.15.0-47-generic (64-bit)
Graphics Platform: X11
Processors: 8 × AMD Ryzen 7 4700U with Radeon Graphics
Memory: 30.7 GiB of RAM
Graphics Processor: AMD RENOIR

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions