[Hackage] #649: better warning messages for why dependencies are missing / cannot be selected

Hackage cvs-ghc at haskell.org
Mon Apr 9 16:39:28 CEST 2012

#649: better warning messages for why dependencies are missing / cannot be
  Reporter:  duncan              |        Owner:  kosmikus          
      Type:  enhancement         |       Status:  closed            
  Priority:  normal              |    Milestone:  cabal-install-0.14
 Component:  cabal-install tool  |      Version:  HEAD              
  Severity:  normal              |   Resolution:  fixed             
  Keywords:  solver              |   Difficulty:  unknown           
Ghcversion:                      |     Platform:                    
Changes (by kosmikus):

  * status:  new => closed
  * resolution:  => fixed


 Here's the error message the modular solver reports in a similar
 situation. I added a number of flags to prevent other solutions from being
 $ cabal install --global --package-db=local aeson- --constraint
 ="unordered-containers installed" --dry-run
 cabal: Could not resolve dependencies:
 trying: aeson- (user goal)
 next goal: unordered-containers (dependency of aeson-
 rejecting: unordered-containers- (package is
 rejecting: unordered-containers-,,,,,,,,,,,,, (global constraint requires installed instance)
 The `unordered-containers-` version is installed in the local
 package DB, but depends on `hashable` which is installed in the user DB.

 If we add the `--user` flag, it works:
 $ cabal install --global --user --package-db=local aeson-
 --constraint="unordered-containers installed" --dry-run
 Resolving dependencies...
 In order, the following would be installed (use -v for more details):

 The error message for the installed constraint is implicitly shown above
 as well. Here's another example:
 $ ~/.cabal/bin/cabal install repa- --dry-run
 Resolving dependencies...
 cabal: Could not resolve dependencies:
 trying: repa- (user goal)
 next goal: base (dependency of repa-
 rejecting: base-, (global constraint requires installed
 rejecting: base- (conflict: repa => base==4.5.*)
 rejecting: base-,,,,,,,,, (global constraint requires installed instance)
 This still lists all versions of `base`, but lists very clearly that we
 can't use any version but because they're not installed, and we
 can't use because repa requires 4.5.

 Closing this bug.

Ticket URL: <http://hackage.haskell.org/trac/hackage/ticket/649#comment:5>
Hackage <http://haskell.org/cabal/>
Hackage: Cabal and related projects

More information about the cabal-devel mailing list