-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
_wait_for_msg() on CPython with TLS connection raises ssl.SSLWantReadError on timeout #154
Comments
@vladak This seems resolved via adafruit/circuitpython#7632 and adafruit/circuitpython#7779. Are you able to test on CircuitPython 8.1.0 Beta 1? |
Actually, looking at the stack trace, this is a problem that seems to happen only with CPython. |
|
@vladak btw - Thank you for your work, PRs, and issues reported on this library. I've had different priorities since writing it (mostly working on Adafruit WipperSnapper). I am getting back to resolving issues with MiniMQTT and enhancing it starting next week. |
The "Out from loop()" message simply means that the For this case, I am not expecting any messages to be received withing the
I've just tried that, still hitting the same issue. |
You are certainly welcome, I had fun doing that.
Cool ! |
When connected via TLS, i.e. the socket is wrapped using the
ssl_context
and if there is nothing to be read in the loop, it results in:In such case,
_wait_for_msg()
should returnNone
, however the ssl exception fires through:Adafruit_CircuitPython_MiniMQTT/adafruit_minimqtt/adafruit_minimqtt.py
Lines 967 to 972 in 342b8c9
Note that the line numbers do not match because I am using minimqtt code for one of my PRs, however that should not matter.
Trouble is that the
ssl.SSLWantReadError
does not seem to be reachable from the ssl context passed toMQTT()
init function. The exception class is based onOSError
, however catching that would be too generic, I think.The text was updated successfully, but these errors were encountered: