Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

If there is ~/.ghc/…/environments/default, cabal install fails. #6512

Closed
kindaro opened this issue Jan 26, 2020 · 1 comment
Closed

If there is ~/.ghc/…/environments/default, cabal install fails. #6512

kindaro opened this issue Jan 26, 2020 · 1 comment

Comments

@kindaro
Copy link

kindaro commented Jan 26, 2020

Describe the bug

Not sure how I arrived there, but since yesterday I cannot install any packages. It looks like
this:

% cabal v2-install optparse-applicative --lib
Resolving dependencies...
cabal: Could not resolve dependencies:
[__0] trying: base-4.12.0.0/installed-4.12.0.0 (user goal)
[__1] trying: containers-0.6.2.1 (user goal)
[__2] next goal: ghc (user goal)
[__2] rejecting: ghc-8.6.5/installed-8.6.5 (conflict: containers==0.6.2.1, ghc
=> containers==0.6.0.1/installed-0.6.0.1)
[__2] trying: ghc-8.6.5
[__3] rejecting: ghc:-buildable (conflict: base==4.12.0.0/installed-4.12.0.0,
ghc -buildable => base<0)
[__3] rejecting: ghc:+buildable (manual flag can only be changed explicitly)
[__3] fail (backjumping, conflict set: base, ghc, ghc:buildable)
After searching the rest of the dependency tree exhaustively, these were the
goals I've had most trouble fulfilling: containers, base, ghc, ghc:buildable
Try running with --minimize-conflict-set to improve the error message.
  • If I remove the store, like rm ~/.cabal/store, the issue gets fixed.
  • If I remove the default environment, like rm ~/.ghc/x86_64-linux-8.6.5/environments/default,
    I can install one library, then the file gets created again, I have to remove it again to
    install more things, and so on indefinitely.

The issue affects only a single version of GHC. I can install things with other GHC versions
without issue. All installations of the same version are affected at once.

To Reproduce

I have a 10 GB store that I can reliably play the issue out from. Tomorrow I am thinking to try and
cut packages from a copy of the store to reduce its volume while making sure the issue remains.

Expected behavior

A library or an executable is installed as usual.

System information

  • Operating system: Arch Linux x86_64.
  • Cabal: Across several versions, including current master.
  • GHC: only 8.6.5. Other versions work fine.

Additional context

We had a conversation with folks on the IRC and it turns out someone else also experienced
this issue. Also see a longer log.

@phadej
Copy link
Collaborator

phadej commented Feb 19, 2020

Duplicate of #5888

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants