stack install ghcide fails

Hello Café, Using stack, I've tried stack install ghcide, it reported to put the following into my global extra-deps: - haskell- lsp-0.17.0.0@sha256:ddfcc2798f04bcb1ec20fafc02c03faa197322192578e879cef5852 aba43ebcb,5264 - haskell-lsp- types-0.17.0.0@sha256:9078237412d0596a7d09d432389c8fa21d6f3e21ed2ed761b3 093a21607d6c28,2941 - hie- bios-0.2.1@sha256:5f98a3516ce65e0a3ffd88bf6fb416b04cc084371d0fbf0e1762780d e1d652ce,3219 - rope-utf16- splay-0.3.1.0@sha256:15a53c57f8413d193054bb5f045929edae3b2669def4c6af6319 7b30dc1d5003,2029 Nevertheless, the build failed anyway: stack install ghcide ghcide> configure ghcide> Configuring ghcide-0.0.4... ghcide> build ghcide> Preprocessing library for ghcide-0.0.4.. ghcide> Building library for ghcide-0.0.4.. ghcide> [ 1 of 33] Compiling Development.IDE.Core.Debouncer ghcide> [ 2 of 33] Compiling Development.IDE.Core.PositionMapping ghcide> [ 3 of 33] Compiling Development.IDE.GHC.Compat ghcide> [ 4 of 33] Compiling Development.IDE.GHC.CPP ghcide> [ 5 of 33] Compiling Development.IDE.Spans.Type ghcide> [ 6 of 33] Compiling Development.IDE.Types.Location ghcide> [ 7 of 33] Compiling Development.IDE.Types.Diagnostics ghcide> [ 8 of 33] Compiling Development.IDE.LSP.Protocol ghcide> [ 9 of 33] Compiling Development.IDE.GHC.Util ghcide> [10 of 33] Compiling Development.IDE.GHC.Orphans ghcide> [11 of 33] Compiling Development.IDE.Import.DependencyInformation ghcide> [12 of 33] Compiling Development.IDE.GHC.Error ghcide> [13 of 33] Compiling Development.IDE.Import.FindImports ghcide> [14 of 33] Compiling Development.IDE.GHC.Warnings ghcide> [15 of 33] Compiling Development.IDE.Core.Preprocessor ghcide> [16 of 33] Compiling Development.IDE.Core.RuleTypes ghcide> [17 of 33] Compiling Development.IDE.Types.Logger ghcide> [18 of 33] Compiling Development.IDE.Types.Options ghcide> [19 of 33] Compiling Development.IDE.Core.Shake ghcide> ghcide> /tmp/stack204611/ghcide-0.0.4/src/Development/IDE/Core/Shake.hs:106:5: error: ghcide> • No instance for (Control.Monad.Fail.MonadFail Rules) ghcide> arising from a do statement ghcide> with the failable pattern ‘Just x’ ghcide> • In a stmt of a 'do' block: ghcide> Just x <- getShakeExtraRules @ShakeExtras ghcide> In the expression: ghcide> do Just x <- getShakeExtraRules @ShakeExtras ghcide> return x ghcide> In an equation for ‘getShakeExtrasRules’: ghcide> getShakeExtrasRules ghcide> = do Just x <- getShakeExtraRules @ShakeExtras ghcide> return x ghcide> | ghcide> 106 | Just x <- getShakeExtraRules @ShakeExtras ghcide> | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ghcide> -- While building package ghcide-0.0.4 using: /home/kolar/.stack/setup-exe-cache/x86_64-linux-tinfo6/Cabal- simple_mPHDZzAJ_2.4.0.1_ghc-8.6.3 --builddir=.stack-work/dist/x86_64-linux-tinfo6/ Cabal-2.4.0.1 build --ghc-options " -fdiagnostics-color=always" Process exited with code: ExitFailure 1 Does that mean the ghcide is broken? Or am I doing something wrong? Best regards, Dusan

On Dec 10, 2019, at 11:03 AM, Dušan Kolář
wrote: -- While building package ghcide-0.0.4 using: /home/kolar/.stack/setup-exe-cache/x86_64-linux-tinfo6/Cabal-simple_mPHDZzAJ_2.4.0.1_ghc-8.6.3 --builddir=.stack-work/dist/x86_64-linux-tinfo6/Cabal-2.4.0.1 build --ghc-options " -fdiagnostics-color=always" Process exited with code: ExitFailure 1
Does that mean the ghcide is broken? Or am I doing something wrong?
Taking a quick look at recent ghcide commits, I see: https://github.com/digital-asset/ghcide/commit/e78e1638ea00af7c5bf4fdbae2454... which shows changes to a stack.yaml file using "resolver: nightly-2019-12-06". The removed extra-deps are: - haskell-lsp-0.18.0.0 - lsp-test-0.8.2.0 - hslogger-1.3.0.0 - network-bsd-2.8.1.0 and the presumably expectation is that these will show up in a stack release soon. But in the mean time you've selected: - haskell-lsp-0.17.0.0 - haskell-lsp-types-0.17.0.0 - hie-bios-0.2.1 - rope-utf16-splay-0.3.1.0 which are older, and may not work with GHC 8.8.1 (MFP changes) used by recent stack nightly builds. You could try changing the stack.yaml file to use an even more recent nightly, but ultimately, may need to figure out the right versions of the extra dependencies. -- Viktor.

cabal install ghcide -w ghc-8.8.1 seems to work, so I don’t think it’s ghcide precisely. Cheers, Vanessa
On Dec 10, 2019, at 10:37 AM, Viktor Dukhovni
wrote: On Dec 10, 2019, at 11:03 AM, Dušan Kolář
wrote: -- While building package ghcide-0.0.4 using: /home/kolar/.stack/setup-exe-cache/x86_64-linux-tinfo6/Cabal-simple_mPHDZzAJ_2.4.0.1_ghc-8.6.3 --builddir=.stack-work/dist/x86_64-linux-tinfo6/Cabal-2.4.0.1 build --ghc-options " -fdiagnostics-color=always" Process exited with code: ExitFailure 1
Does that mean the ghcide is broken? Or am I doing something wrong?
Taking a quick look at recent ghcide commits, I see:
https://github.com/digital-asset/ghcide/commit/e78e1638ea00af7c5bf4fdbae2454...
which shows changes to a stack.yaml file using "resolver: nightly-2019-12-06". The removed extra-deps are:
- haskell-lsp-0.18.0.0 - lsp-test-0.8.2.0 - hslogger-1.3.0.0 - network-bsd-2.8.1.0
and the presumably expectation is that these will show up in a stack release soon. But in the mean time you've selected:
- haskell-lsp-0.17.0.0 - haskell-lsp-types-0.17.0.0 - hie-bios-0.2.1 - rope-utf16-splay-0.3.1.0
which are older, and may not work with GHC 8.8.1 (MFP changes) used by recent stack nightly builds. You could try changing the stack.yaml file to use an even more recent nightly, but ultimately, may need to figure out the right versions of the extra dependencies.
-- Viktor.
_______________________________________________ Haskell-Cafe mailing list To (un)subscribe, modify options or view archives go to: http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe Only members subscribed via the mailman list are allowed to post.

Smells a bit like it only applies the MonadFail instance in ghc 8.8.1, but
the build log said ghc 8.6 and implied MonadFailDesugaring enabled from the
error message.
On Tue, Dec 10, 2019 at 11:42 AM Vanessa McHale
cabal install ghcide -w ghc-8.8.1 seems to work, so I don’t think it’s ghcide precisely.
Cheers, Vanessa
On Dec 10, 2019, at 10:37 AM, Viktor Dukhovni
wrote: On Dec 10, 2019, at 11:03 AM, Dušan Kolář
wrote: -- While building package ghcide-0.0.4 using: /home/kolar/.stack/setup-exe-cache/x86_64-linux-tinfo6/Cabal-simple_mPHDZzAJ_2.4.0.1_ghc-8.6.3 --builddir=.stack-work/dist/x86_64-linux-tinfo6/Cabal-2.4.0.1 build --ghc-options " -fdiagnostics-color=always" Process exited with code: ExitFailure 1
Does that mean the ghcide is broken? Or am I doing something wrong?
Taking a quick look at recent ghcide commits, I see:
https://github.com/digital-asset/ghcide/commit/e78e1638ea00af7c5bf4fdbae2454...
which shows changes to a stack.yaml file using "resolver: nightly-2019-12-06". The removed extra-deps are:
- haskell-lsp-0.18.0.0 - lsp-test-0.8.2.0 - hslogger-1.3.0.0 - network-bsd-2.8.1.0
and the presumably expectation is that these will show up in a stack release soon. But in the mean time you've selected:
- haskell-lsp-0.17.0.0 - haskell-lsp-types-0.17.0.0 - hie-bios-0.2.1 - rope-utf16-splay-0.3.1.0
which are older, and may not work with GHC 8.8.1 (MFP changes) used by recent stack nightly builds. You could try changing the stack.yaml file to use an even more recent nightly, but ultimately, may need to figure out the right versions of the extra dependencies.
-- Viktor.
_______________________________________________ Haskell-Cafe mailing list To (un)subscribe, modify options or view archives go to: http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe Only members subscribed via the mailman list are allowed to post.
_______________________________________________ Haskell-Cafe mailing list To (un)subscribe, modify options or view archives go to: http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe Only members subscribed via the mailman list are allowed to post.
-- brandon s allbery kf8nh allbery.b@gmail.com

Well, a few moments ago, I was able to successfully run with:
stack install ghcide --compiler ghc-8.8.1
and stack.yaml:
extra-deps:
- haskell-lsp-0.17.0.0
- haskell-lsp-types-0.17.0.0
resolver: nightly-2019-12-06
even if stack was complaining about versions of ghc and cabal.
Thanks and regards
Dusan
Smells a bit like it only applies the MonadFail instance in ghc 8.8.1, but the build log
said ghc 8.6 and implied MonadFailDesugaring enabled from the error message.
On Tue, Dec 10, 2019 at 11:42 AM Vanessa McHale
participants (4)
-
Brandon Allbery
-
Dušan Kolář
-
Vanessa McHale
-
Viktor Dukhovni