vdukhovni / danecheck

DANE SMTP checker
BSD 3-Clause "New" or "Revised" License
34 stars 4 forks source link

Module ‘Network.TLS’ does not export #6

Open postme opened 4 years ago

postme commented 4 years ago

Hi there,

I'm getting the following error whilst building danecheck on Amazon Linux 2:

Building all executables for `danecheck' once. After a successful build of all of them, only specified executables will be rebuilt.
danecheck> build (exe)
danecheck> Preprocessing executable 'danecheck' for danecheck-1.1.0..
danecheck> Building executable 'danecheck' for danecheck-1.1.0..
danecheck> [ 7 of 16] Compiling Dane.Scanner.SMTP.TLS
danecheck>
danecheck> /home/ec2-user/danecheck/Dane/Scanner/SMTP/TLS.hs:30:31: error:
danecheck>     Module
danecheck>     ‘Network.TLS’
danecheck>     does not export
danecheck>     ‘Version(TLS10, TLS11, TLS12, TLS13)’
danecheck>    |
danecheck> 30 | import           Network.TLS (Version(TLS10, TLS11, TLS12, TLS13))
danecheck>    |                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
danecheck>

--  While building package danecheck-1.1.0 using:
      /home/ec2-user/.stack/setup-exe-cache/x86_64-linux/Cabal-simple_mPHDZzAJ_2.4.0.1_ghc-8.6.5 --builddir=.stack-work/dist/x86_64-linux/Cabal-2.4.0.1 build exe:danecheck --ghc-options " -fdiagnostics-color=always"
    Process exited with code: ExitFailure 1

Any idea how I could solve this? I tried googling the error but it's not yielding results and I'm not proficient with Haskell.

Kind regards Meint

sshambar commented 4 years ago

I received the same error; took a little research to track down how to fix it (as I've never used Haskell either :). Looks like the snapshot doesn't include a compatible TLS dependency, but you can manually add a later version of tls with the following addition to stack.yml, just after the "extra-deps:" line:

- tls-1.5.2@sha256:61e403d59c860fe9df2ff15bf2aa73a75fa1fb53f7ac27a62d1f40f23d30f26c,6753