Exception: SSL read() error: error:0A000126:SSL routines::unexpected eof while reading.
abhsrivastava opened this issue · comments
Google brought me to this thread.
I am using Cohttp Async to make a call to this URL https://api.weather.gov/points/48.0698,-121.8151 (it opens fine in browsers)
However when I do Client.get I get an error
Exception: SSL read() error: error:0A000126:SSL routines::unexpected eof while reading.
Please tell me how to troubleshoot. My code base is here just in case anyone wants to have a look at it.
I could not yet test this, however I saw this error in another library linking openssl some time ago. In that case it was related to https://www.openssl.org/docs/manmaster/man3/SSL_CTX_set_options.html#SSL_OP_IGNORE_UNEXPECTED_EOF (the option was added to openssl one or two years ago I think). I don’t think ocaml-ssl allows to set it.
If you install tls-lwt and run your code with the environment variable CONDUIT_TLS=native, do you still see the issue?
the above suggestion worked. I installed tis-lwt and set environment variable and now error is gone. thanks