尽管有这些错误,我该如何安装 elm-repl?

How do I install elm-repl despite these errors?

我对 elm 和 web 开发总体上是全新的。我正在阅读指南 here. I installed Sublime Text and the elm compiler. I'd like to use a REPL to play around with things easily. I tried installing it through the instructions here,其中我 运行 这个:

cabal update ; cabal install elm-repl

但是我得到这个错误:

Resolving dependencies...
Configuring http-client-0.5.8...
Building http-client-0.5.8...
Failed to install http-client-0.5.8
Build log ( /home/matt/.cabal/logs/http-client-0.5.8.log ):
cabal: Entering directory '/tmp/cabal-tmp-9068/http-client-0.5.8'
Configuring http-client-0.5.8...
Building http-client-0.5.8...
Preprocessing library http-client-0.5.8...
[ 1 of 19] Compiling Network.PublicSuffixList.Types ( publicsuffixlist/Network/PublicSuffixList/Types.hs, dist/build/Network/PublicSuffixList/Types.o )
[ 2 of 19] Compiling Network.PublicSuffixList.Serialize ( publicsuffixlist/Network/PublicSuffixList/Serialize.hs, dist/build/Network/PublicSuffixList/Serialize.o )
[ 3 of 19] Compiling Network.PublicSuffixList.DataStructure ( publicsuffixlist/Network/PublicSuffixList/DataStructure.hs, dist/build/Network/PublicSuffixList/DataStructure.o )
[ 4 of 19] Compiling Network.PublicSuffixList.Lookup ( publicsuffixlist/Network/PublicSuffixList/Lookup.hs, dist/build/Network/PublicSuffixList/Lookup.o )
[ 5 of 19] Compiling Network.HTTP.Client.Util ( Network/HTTP/Client/Util.hs, dist/build/Network/HTTP/Client/Util.o )
[ 6 of 19] Compiling Data.KeyedPool   ( Data/KeyedPool.hs, dist/build/Data/KeyedPool.o )
[ 7 of 19] Compiling Network.HTTP.Client.Types ( Network/HTTP/Client/Types.hs, dist/build/Network/HTTP/Client/Types.o )
[ 8 of 19] Compiling Network.HTTP.Client.Connection ( Network/HTTP/Client/Connection.hs, dist/build/Network/HTTP/Client/Connection.o )
[ 9 of 19] Compiling Network.HTTP.Client.Body ( Network/HTTP/Client/Body.hs, dist/build/Network/HTTP/Client/Body.o )
[10 of 19] Compiling Network.HTTP.Client.Cookies ( Network/HTTP/Client/Cookies.hs, dist/build/Network/HTTP/Client/Cookies.o )

Network/HTTP/Client/Cookies.hs:152:38: error:
    • Couldn't match expected type ‘Builder’
                  with actual type ‘Data.ByteString.Builder.Internal.Builder’
      NB: ‘Data.ByteString.Builder.Internal.Builder’
            is defined in ‘Data.ByteString.Builder.Internal’
                in package ‘bytestring-0.10.8.1’
          ‘Builder’
            is defined in ‘Blaze.ByteString.Builder.Internal.Types’
                in package ‘blaze-builder-0.3.3.4’
    • In the second argument of ‘($)’, namely
        ‘renderCookies $ output_cookies’
      In the expression: toByteString $ renderCookies $ output_cookies
      In an equation for ‘output_line’:
          output_line = toByteString $ renderCookies $ output_cookies
cabal: Leaving directory '/tmp/cabal-tmp-9068/http-client-0.5.8'
cabal: Error: some packages failed to install:
Elm-0.12.3 depends on http-client-0.5.8 which failed to install.
elm-repl-0.2.2.1 depends on http-client-0.5.8 which failed to install.
http-client-0.5.8 failed during the building phase. The exception was:
ExitFailure 1
http-client-tls-0.3.5.3 depends on http-client-0.5.8 which failed to install.
pandoc-2.1 depends on http-client-0.5.8 which failed to install.

如果您已经安装了 Elm 编译器,那么您已经有了 REPL。尝试在 shell 中输入 elm repl。请注意,此命令中没有连字符。

安装单独 REPL 所遵循的说明早已过时。