4

I just installed Stack using

curl -sSL https://get.haskellstack.org/ | sh

The install went fine but when trying to install Intero using Stack it fails

ffriis@BNEC02QR6Y0G8WN ~> stack install hlint intero

Error: While constructing the build plan, the following exceptions were encountered:

In the dependencies for intero-0.1.32:
    ghc-8.4.4 from stack configuration does not match >=7.8 && <=8.4.3  (latest matching version is 8.4.3)
needed since intero is a build target.

Some different approaches to resolving this:

  * Set 'allow-newer: true' in /Users/ffriis/.stack/config.yaml to ignore all version constraints and build anyway.

  * Consider trying 'stack solver', which uses the cabal-install solver to attempt to find some working build configuration. This can be convenient when dealing with many complicated constraint
    errors, but results may be unpredictable.

  * Recommended action: try adding the following to your extra-deps in /Users/ffriis/.stack/global-project/stack.yaml:

ghc-8.4.3@sha256:07ee8fb5dab414c35f93d5d5afc1ecaa65a49c409346e5063436cc8b838cd754

Plan construction failed.

I've edited the file as instructed but I'm still getting the same error. What is the best way to resolve the problem?

fred
  • 1,812
  • 3
  • 37
  • 57
  • 1
    You probably shouldn't install `intero` directly using `stack install` like this (see [here](https://lexi-lambda.github.io/blog/2018/02/10/an-opinionated-guide-to-haskell-in-2018/#understanding-stacks-model-and-avoiding-its-biggest-gotcha)); what happens if you let emacs install it for you? – bradrn Nov 02 '18 at 10:45
  • 1
    I can also confirm this. But it looks like intero can only support up to GHC `8.4.3` at this time. – Ashesh Nov 04 '18 at 10:58

1 Answers1

5

Currently intero supports GHC 8.4.3, but stack is grabbing 8.4.4. Change your resolver to lts-12.14 in stack.yaml

tylerweir
  • 1,265
  • 11
  • 16