[Hackage] #470: identify and exclude broken or unusable packages when constructing and merging package dbs

Hackage cvs-ghc at haskell.org
Thu Apr 5 18:31:59 CEST 2012

#470: identify and exclude broken or unusable packages when constructing and
merging package dbs
  Reporter:  guest               |        Owner:  kosmikus          
      Type:  defect              |       Status:  new               
  Priority:  normal              |    Milestone:  cabal-install-0.14
 Component:  cabal-install tool  |      Version:           
  Severity:  normal              |     Keywords:  solver            
Difficulty:  hard (< 1 day)      |   Ghcversion:                    
  Platform:                      |  

Comment(by kosmikus):

 This turned out to be trickier than I first expected.

 The problem is that the underlying shadowing is an incredibly
 subtle thing.

 Here are a few facts:

    * The new modular solver produces a better error message.
    * Unlike the old (topdown) solver, the modular solver will just
 consider multiple installed instances of a package to all be available,
 even if they have the same version.
    * It's possible to install packages with cabal-install that ghc/ghci
 will not be able to load with a simple -package flag, because GHC applies
 shadowing in such a situation. However, explicitly selecting the packages
 with -package-id should help in such a case.
    * It's possible for Cabal to fail at build time because currently, the
 interface between cabal-install and the build process is suboptimal. We
 only pass version constraints to the individual package builds, not the
 exact package identities, even if we have them.
    * I've added functionality to the modular solver so that it can, if
 desired, apply shadowing itself, by disabling packages from the installed
 package index.
    * Broken packages with missing dependencies should be disabled now in
 the solver.
    * Applying shadowing seems like the wrong thing to do, though, and
 despite the lossy flag passing to the builder, the situations that fail
 are rare (fewer than would be rejected if shadowing was enabled in the
 index). So I've disabled shadowing for now.

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

More information about the cabal-devel mailing list