Unhelpful error message for "module found in multiple packages" #587

bos opened this Issue May 24, 2012 · 2 comments


None yet

2 participants

bos commented May 24, 2012

(Imported from Trac #594, reported by chevalier on 2009-09-29)

I was checking whether cabal-install would install my "extcore" package, and got:

$ sudo cabal install extcore --enable-library-profiling --reinstall
Resolving dependencies...
Configuring extcore-0.3...
Preprocessing library extcore-0.3...
Building extcore-0.3...
    Could not find module `Data.Generics':
      it was found in multiple packages: base- syb
cabal: Error: some packages failed to install:
extcore-0.3 failed during the building phase. The exception was:
exit: ExitFailure 1
This is an unhelpful error message because it gives the user no information about what they have to do to continue. Since I'm the package author, I was able to figure out that I needed to change the .cabal file to depend on base >= 4. In general, the error message should explain that this is a bug in the package description and to report it to the package maintainer.

cabal-install 0.6.2, library version

bos commented May 24, 2012

(Imported comment by @dcoutts on 2009-09-29)

There's very little we can do about this until Cabal does the dependency tracking itself rather than leaving it to ghc --make.

In the mean time it might be possible to get ghc to report a more helpful error message. Against my better judgement, ghc recently added a flag to distinguish whether it is being called by cabal or by the end user so that it can target error messages better.

tibbe commented May 15, 2014

Closing as there's been no activity in years.

We're cleaning up the bug tracker to make it useful again and are thus closing bugs that haven't seen any activity in a long time. Please re-open (or file a new bug) if the problem reappears.

@tibbe tibbe closed this May 15, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment