堆栈“计划构建失败。”

Leo*_*ang 5 haskell haskell-stack

我正在尝试在项目中使用以下命令构建本地 hoogle 服务器,该项目lts-11.1用作解析器stack.yaml

stack hoogle -- server --local --port=8080
Run Code Online (Sandbox Code Playgroud)

它曾经可以工作,但现在由于此错误而失败:

? stack hoogle -- server --local --port=8080
Hoogle isn't installed. Automatically installing (use --no-setup to disable) ...
Minimum version is hoogle-5.0. Found acceptable hoogle-5.0.17.6 in your index, installing it.

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

In the dependencies for hoogle-5.0.17.6:
    haskell-src-exts-1.20.3 from stack configuration does not match >=1.21 && <1.22  (latest matching version is 1.21.0)
needed since hoogle is a build target.

Some different approaches to resolving this:

  * Set 'allow-newer: true' in /Users/leo/.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/leo/.stack/global-project/stack.yaml:

haskell-src-exts-1.21.0@sha256:02421cacaa48c055551b8e5796efc543301b7ea9527a38e1385403d2b85512fb

Plan construction failed.
Run Code Online (Sandbox Code Playgroud)

里面/Users/leo/.stack/global-project/stack.yamlresolver: lts-13.15

很久以前当我在做那个项目时,我使用ghc8.2.2with lts-11.1. 我最近在我的笔记本电脑上重新安装了所有东西,包括haskell-stack,现在我的stack --version1.9.3 x86_64,无法构建 hoogle。不确定是因为我的堆栈版本还是其他原因。

我该如何解决?