ITADN

hie.yaml should take priority over cabal/stack as the `project_root`

#505OpenMangoIV 创建于 2025-09-11
M
MangoIVcommented
Hi! I think wrt project root detection, it would be good to have hie.yaml take priority over cabal or stack project root detection, as, if it exists, it usually specifies a more specific cradle than the one specified by stack or cabal. This is problematic in practice, since e.g. GHC has a `ghc.cabal.in` file in the `./compiler` subdir, so haskell-tools detects the project root to be `./compiler`(and not `./.`) but then the hie.yaml still starts the cradle from `./.` which is no `./compiler` and thus fails. An alternative fix to the issue at hand would be to allow the user to set the project root dir when invoking the language server via the `Hls` command. Tell me which solution you would prefer and if I should tackle one of them. Hope you're doing well!
10 条评论