You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
cabal install can't install new versions of a package on ghc 8.8.1 #98
cabal --version
cabal --version
cabal-install version 3.0.0.0
compiled using version 3.0.0.0 of the Cabal library
bash-3.2$ cabal install directory
cabal install directory
Resolving dependencies...
cabal: Could not resolve dependencies:
[__0] trying: directory-1.3.4.0 (user goal)
[__1] next goal: ghc (user goal)
[__1] rejecting: ghc-8.8.1/installed-8.8... (conflict: directory==1.3.4.0, ghc
=> directory==1.3.3.2/installed-1.3...)
[__1] rejecting: ghc-8.6.5, ghc-8.6.4, ghc-8.6.1, ghc-8.4.4, ghc-8.4.3,
ghc-8.4.1, ghc-8.2.2, ghc-8.2.1 (constraint from user target requires ==8.8.1)
[__1] fail (backjumping, conflict set: directory, ghc)
After searching the rest of the dependency tree exhaustively, these were the
goals I've had most trouble fulfilling: directory, ghc
I believe this caused by the difference in behavior between cabal v1-install and cabal v2-install. You are currently using v2-install, which installs to a package environment file such as ~/.ghc/${arch}-${os}/environments/default. In that environment file (which you can inspect with a text editor), directory-1.3.3.2 is probably already installed, so you cannot install a different version.
To work around this, you can try to install to a new environment, say ./foobar.env:
Is there a user guide for cabal 3.0? I find it a big change where much of what I used to do doesn't work. These differences feel like regressions to me. I'm concerned that many unsophisticated users will feel the same. Previously we didn't really have to know about package env files. I think new ghc users will find the ecosystem more daunting than previously. I just wanted to give my feedback.
BTW cabal upgrade is also confusing:
$ cabal upgrade directory
fromFlag NoFlag. Use fromFlagOrDefault
CallStack (from HasCallStack):
error, called at ./Distribution/Simple/Flag.hs:96:21 in Cbl-3.0.0.0-d96b8c70:Distribution.Simple.Flag
fromFlag, called at main/Main.hs:903:15 in main:Main
On Sun, Oct 13, 2019 at 10:03 AM GeorgeCo ***@***.***> wrote:
Is there a user guide for cabal 3.0? I find it a big change where much of
what I used to do doesn't work. These differences feel like regressions to
me. I'm concerned that many unsophisticated users will feel the same.
Previously we didn't really have to know about package env files. I think
new ghc users will find the ecosystem more daunting than previously. I just
wanted to give my feedback.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#98?email_source=notifications&email_token=AAABBQWZAON7FBDZZPYKGWLQOMTC5A5CNFSM4I6LTNZKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEBCW4NQ#issuecomment-541421110>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAABBQVMJYONLIZRA63NUX3QOMTC5ANCNFSM4I6LTNZA>
.
There is some bit of documentation in the Cabal user guide on the new changes but I do agree it is quite confusing and the migration path is not adequately explained. It did take me some time to figure out what was causing the issue your described.
I do suggest posting your feedback on the Cabal project itself, not here, as I'm not sure whether the maintainers of Cabal would see this thread.
I think I did and I think it worked but I'm not anxious to learn about the v2 version of stuff until I understand the motivation for the incompatible changes. I haven't looked hard but I'm unaware of a design doc for cabal 3.0 that explains that. I did check the GHC 8.8.1 User's Guide for a link to some documentation to Cabal 3.0 but I didn't see any. Hopefully I'll learn something from my cabal bug report.
Activity
Rufflewind commentedon Oct 13, 2019
I believe this caused by the difference in behavior between
cabal v1-installandcabal v2-install. You are currently usingv2-install, which installs to a package environment file such as~/.ghc/${arch}-${os}/environments/default. In that environment file (which you can inspect with a text editor),directory-1.3.3.2is probably already installed, so you cannot install a different version.To work around this, you can try to install to a new environment, say
./foobar.env:GeorgeCo commentedon Oct 13, 2019
Is there a user guide for cabal 3.0? I find it a big change where much of what I used to do doesn't work. These differences feel like regressions to me. I'm concerned that many unsophisticated users will feel the same. Previously we didn't really have to know about package env files. I think new ghc users will find the ecosystem more daunting than previously. I just wanted to give my feedback.
BTW cabal upgrade is also confusing:
[-]cabal doesn't install on ghc 8.8.1[/-][+]cabal install can't install new versions of a package on ghc 8.8.1[/+]cartazio commentedon Oct 13, 2019
Rufflewind commentedon Oct 14, 2019
There is some bit of documentation in the Cabal user guide on the new changes but I do agree it is quite confusing and the migration path is not adequately explained. It did take me some time to figure out what was causing the issue your described.
I do suggest posting your feedback on the Cabal project itself, not here, as I'm not sure whether the maintainers of Cabal would see this thread.
GeorgeCo commentedon Nov 11, 2019
Thanks Rufflewind, cartazio. Sorry it took me so long to post to the Cabal project but I finally did: haskell/cabal#6342
GeorgeCo commentedon Nov 11, 2019
By the way, I was surprised and please to find that " cabal v1-install directory" works fine
Rufflewind commentedon Nov 12, 2019
@GeorgeCo Did you try the workaround suggested above?
GeorgeCo commentedon Nov 12, 2019
I think I did and I think it worked but I'm not anxious to learn about the v2 version of stuff until I understand the motivation for the incompatible changes. I haven't looked hard but I'm unaware of a design doc for cabal 3.0 that explains that. I did check the GHC 8.8.1 User's Guide for a link to some documentation to Cabal 3.0 but I didn't see any. Hopefully I'll learn something from my cabal bug report.