Understanding new-style cabal #572
Description
I'm having a hard time using the new cabal install.
For example if I do cabal install
in the tidal folder, it'll work the first time, but if I make an edit and do that again, I end up with two versions of tidal with the same version number, and ghci will no longer load it. I have to edit ~/.ghc/x86_64-linux-8.6.5/environments/default
to remove tidal and try again, then it works.
However this morning, it's not installing at all:
alex@stanage:~/src/tidal$ cabal install
Wrote tarball sdist to
/home/alex/src/tidal/dist-newstyle/sdist/tidal-1.4.4.tar.gz
Wrote tarball sdist to
/home/alex/src/tidal/dist-newstyle/sdist/tidal-parse-0.0.1.tar.gz
Resolving dependencies...
cabal: Could not resolve dependencies:
[__0] trying: base-4.12.0.0/installed-4.1... (user goal)
[__1] trying: ghc-8.6.5/installed-8.6... (user goal)
[__2] next goal: process (user goal)
[__2] rejecting: process-1.6.6.0 (conflict: ghc =>
process==1.6.5.0/installed-1.6...)
[__2] rejecting: process-1.6.5.1, process-1.6.5.0/installed-1.6...,
process-1.6.5.0, process-1.6.4.0, process-1.6.3.0, process-1.6.2.0,
process-1.6.1.0, process-1.6.0.0, process-1.5.0.0, process-1.4.3.0,
process-1.4.2.0, process-1.4.1.0, process-1.4.0.0, process-1.3.0.0,
process-1.2.3.0, process-1.2.2.0, process-1.2.1.0, process-1.2.0.0,
process-1.1.0.2, process-1.1.0.1, process-1.1.0.0, process-1.0.1.5,
process-1.0.1.4, process-1.0.1.3, process-1.0.1.2, process-1.0.1.1,
process-1.0.0.0 (constraint from user target requires ==1.6.6.0)
[__2] fail (backjumping, conflict set: ghc, process)
After searching the rest of the dependency tree exhaustively, these were the
goals I've had most trouble fulfilling: process, base, ghc, ghc:buildable
Try running with --minimize-conflict-set to improve the error message.
I'm not sure why this is, the only thing I can think is that I installed some additional packages last night, including a binary that depends on tidal (https://github.com/yaxu/feedforward).
My feeling is that installing global packages isn't working too well. So what should we do instead? Probably if we embraced the new way of doing things we'd have a lot fewer install problems, but I'm not sure what that is..