haskell / haskell-ide-engine

The engine for haskell ide-integration. Not an IDE
BSD 3-Clause "New" or "Revised" License
2.38k stars 211 forks source link

Getting started with hacking on HIE #1455

Open asheshambasta opened 4 years ago

asheshambasta commented 4 years ago

I've been looking into how I can dive into the code and (hopefully) contribute, but after doing a git clone (git clone --recurse-submodules -j8 git@github.com:haskell/haskell-ide-engine.git), I cannot seem to get the GHCi (stack ghci) fired up on the master branch:

hlint-2.2.3: configure                                
hie-plugin-api-0.13.0.0: copy/register                
Building all executables for `HaRe' once. After a successful build of all of them, only specified executables will be rebuilt.
hlint-2.2.3: build                                    
HaRe-0.8.4.1: configure (lib + exe)        
HaRe-0.8.4.1: build (lib + exe)            
HaRe-0.8.4.1: copy/register                
hlint-2.2.3: copy/register                 
Building all executables for `haskell-ide-engine' once. After a successful build of all of them, only specified executables will be rebuilt.
haskell-ide-engine-0.13.0.0: configure (lib + internal-lib + exe)
haskell-ide-engine-0.13.0.0: initial-build-steps (lib + internal-lib + exe)
Completed 233 action(s).                     
Log files have been written to: /home/ashesh/code/asheshambasta/haskell-ide-engine/.stack-work/logs/
The following GHC options are incompatible with GHCi and have not been passed to it: -Werror -threaded -O0
Configuring GHCi with the following packages: haskell-ide-engine, hie-plugin-api, HaRe
GHCi, version 8.6.5: http://www.haskell.org/ghc/  :? for help
<command line>: cannot satisfy -package z-haskell-ide-engine-z-hie-test-utils
    (use -v for more information)

How can this be fixed?

mpickering commented 4 years ago

What about stack repl haskell-ide-engine?

FYI most of us are using cabal I think to do development and the development effort is concentrated on this fork - https://github.com/mpickering/haskell-ide-engine/

One of the most useful things you could do right now would be to test the fork on some of your projects and report back if there are any issues.

asheshambasta commented 4 years ago

What about stack repl haskell-ide-engine?

This also fails.

One of the most useful things you could do right now would be to test the fork on some of your projects and report back if there are any issues.

Okay, got that. I'm still using ghc-8.4.4 though. Can you please tell me which hashes etc. I need to pin for which ghc version?

I'm also using NixOS with all-hies, which I assume do not supply the hies based off this fork, correct?

mpickering commented 4 years ago

@asheshambasta No, all-hies also packages at least some version of the branch - https://github.com/Infinisil/all-hies#hie-bios-versions

nponeccop commented 4 years ago

Okay, got that. I'm still using ghc-8.4.4 though. Can you please tell me which hashes etc. I need to pin for which ghc version?

Stack snapshots are GHC version specific. So in your project you need to use a snapshot for 8.4.4 . stack-8.4.4.yaml contains the newest snapshot for 8.4.4 so use that one.