Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/html/82.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Haskell 当指定的额外dep超出依赖项时,堆栈无法在快照中找到包';s版本边界_Haskell_Haskell Stack - Fatal编程技术网

Haskell 当指定的额外dep超出依赖项时,堆栈无法在快照中找到包';s版本边界

Haskell 当指定的额外dep超出依赖项时,堆栈无法在快照中找到包';s版本边界,haskell,haskell-stack,Haskell,Haskell Stack,我有一个包。yaml包含 dependencies: - aeson >= 0.8 && < 1.5 - base >= 4.7 && < 5 - time >= 1.5 && < 1.10 但是,当我运行堆栈构建时,我得到了输出 WARNING: Ignoring aeson's bounds on time (>=1.4 && <1.9); using time-1.9.2. R

我有一个
包。yaml
包含

dependencies:
- aeson >= 0.8 && < 1.5
- base >= 4.7 && < 5
- time >= 1.5 && < 1.10
但是,当我运行
堆栈构建
时,我得到了输出

WARNING: Ignoring aeson's bounds on time (>=1.4 && <1.9); using time-1.9.2.
Reason: trusting snapshot over cabal file dependency information.

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

In the dependencies for base-compat-0.10.5:
    unix needed, but the stack configuration has no specified version  (latest matching version is 2.7.2.2)
needed due to tmphaskell-0.1.0.0 -> base-compat-0.10.5

Some different approaches to resolving this:

  * Recommended action: try adding the following to your extra-deps in /Users/will/src/tmphaskell/stack.yaml:

- unix-2.7.2.2@sha256:e69269a17b9fa26cb77f3f55e86c39d0a4940ccfa0c4bc20826919d2572076ad,3496

Plan construction failed.
警告:忽略aeson的时间界限(>=1.4&&base-compat-0.10.5)
解决此问题的一些不同方法:
*建议的操作:尝试将以下内容添加到/Users/will/src/tmphaskell/stack.yaml中的额外DEP中:
-unix-2.7.2。2@sha256:e69269a17b9fa26cb77f3f55e86c39d0a4940ccfa0c4bc20826919d2572076ad,3496
计划建设失败了。
关于此
unix-2.7.2.2
的我不了解的内容确实存在于
lts-14.4
快照中,那么为什么堆栈找不到指定的版本呢

在升级到
2.1.3
之前,此配置适用于旧版本的stack。我不确定以前运行的是哪个版本。

aeson
(通过
base compat
)取决于
unix
time
unix
是ghc启动包,两者都需要作为
额外的deps
添加

原因是?不必匹配他们的黑客版本,所以如果你覆盖一个启动包,你还必须显式覆盖你使用的任何其他启动包

资料来源:

(编辑固定错误;误读精确错误)。

aeson
(通过
base compat
)依赖于
unix
,而作为
time
unix
是ghc启动包,两者都需要作为
额外的deps
添加

原因是?不必匹配他们的黑客版本,所以如果你覆盖一个启动包,你还必须显式覆盖你使用的任何其他启动包

资料来源:


(编辑修复错误;误读精确错误)。

我将您的配置复制粘贴到一个新的堆栈项目上,
堆栈构建
在我的机器上运行良好。我认为您要么没有提供足够的信息(可能您有其他依赖项?或者某些特定的代码?)或者它特定于您的计算机?注意:我在Windows上。@Sir4ur0n您使用的是哪个版本的
stack
?正如我所说,这似乎只影响较新版本的stack。最新版本(2.1.3)我将您的配置复制粘贴到一个新的堆栈项目上,并且
堆栈构建
在我的机器上运行良好。我认为您要么没有提供足够的信息(可能您有其他依赖项?或者某些特定的代码?)或者它特定于您的计算机?注意:我在Windows上。@Sir4ur0n您使用的是哪个版本的
stack
?正如我所说,这似乎只影响较新版本的stack。最新版本(2.1.3)有趣。你知道为什么我的配置在早期版本的
stack
,而不是最新版本中工作吗?半相关:
stack
由于tmphaskell-0.1.0.0->base-compat-0.10.5,当前打印所需的
。是否有方法打印完整的依赖链,例如:
tmphaskell-0.1.0.0->aeson->base-compat-0.10.5
?关于更改,是的!它在堆栈2.1中是新的。至于完整的链,我认为没有选择。它会有帮助吗?是的,我认为它会有用。我在这里发布的示例是一个玩具项目。实际上,我的依赖关系图要复杂得多。我必须打印出整个依赖关系图以了解我是如何依赖的“遇到以下异常”中列出的程序包上的ng。有意思。你知道为什么我的配置在以前版本的
堆栈
,而不是最新版本中工作吗?半相关:
堆栈
当前打印所需的
,因为tmphaskell-0.1.0.0->base-compat-0.10.5
。是否有方法打印完整的依赖链,例如:
tmphaskell-0.1.0.0->aeson->base-compat-0.10.5
?关于更改,是的!它在堆栈2.1中是新的。至于完整的链,我认为没有选择。它会有帮助吗?是的,我认为它会有用。我在这里发布的示例是一个玩具项目。实际上,我的依赖关系图要复杂得多。我必须打印出整个依赖关系图,以了解我是如何依赖的在“遇到以下异常”中列出的程序包上进行检查。
WARNING: Ignoring aeson's bounds on time (>=1.4 && <1.9); using time-1.9.2.
Reason: trusting snapshot over cabal file dependency information.

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

In the dependencies for base-compat-0.10.5:
    unix needed, but the stack configuration has no specified version  (latest matching version is 2.7.2.2)
needed due to tmphaskell-0.1.0.0 -> base-compat-0.10.5

Some different approaches to resolving this:

  * Recommended action: try adding the following to your extra-deps in /Users/will/src/tmphaskell/stack.yaml:

- unix-2.7.2.2@sha256:e69269a17b9fa26cb77f3f55e86c39d0a4940ccfa0c4bc20826919d2572076ad,3496

Plan construction failed.