当运行
yesod devel
时,我在我的应用程序中遇到了以下问题。开始很好(编译完成),但在预处理可执行文件时出现故障:
正在解决依赖项... 配置WebToKindle-0.0.0... 重建应用程序... 由于config/models强制重新编译./Model.hs 由于config/routes强制重新编译./Foundation.hs 由于messages/en.msg强制重新编译./Foundation.hs 由于templates/default-layout-wrapper.hamlet强制重新编译./Foundation.hs 由于templates/default-layout.hamlet强制重新编译./Foundation.hs 由于templates/homepage.hamlet强制重新编译./Handler/Root.hs 预处理库WebToKindle-0.0.0... 预处理WebToKindle-0.0.0的可执行文件... 构建WebToKindle-0.0.0...
Application.hs:22:8: 找不到模块
Network.HTTP.Conduit': 它是hidden package http-conduit-1.2.6'的成员。 也许您需要将http-conduit添加到.cabal文件的build-depends中。 使用-v查看搜索的文件列表。构建失败,暂停...
使用cabal install
安装我的应用程序可以正常工作,我能够启动它并在浏览器中浏览起始页。所以这个问题似乎只在devel
工具中出现。
我尝试注销相关的包并重新安装它们,以帮助cabal找出依赖关系。
cabal install yesod yesod-auth authenticate http-conduit
不幸的是,那没有改变任何事情。由于我想享受“即时满足”开发的好处,我感谢任何帮助我解决这个问题的人。
更新:经过一段时间的调试和monadic的帮助,我找到了问题的源头。问题在于我已经将cabal文件中的cabal版本更改为1.8。我将其改回1.6,现在一切正常。
yesod devel
构建,因此这非常合理。 - alternative