-
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
Loop crashes after successful connecting to HiveMQ (tls) #196
Comments
same problem |
There is something about Pico W and the negative 116, see #177 (comment) |
Not much of a contribution, but I just wanted to mention that I am also facing exactly this problem on a similar environment:
|
Can you try with 9.0.0? This was caught in the 8->9 path that the Pico did errors differently. |
Yes indeed. I have just tried to run it with CircuitPython 9.0.3 and it worked fine without the exception I faced with 8.2.10. |
@philipphock are you willing to test in CP9? We should be able to close this out |
I believe this should be moved to CP issues. |
I used the sample code from "https://github.com/adafruit/Adafruit_CircuitPython_MiniMQTT/blob/main/examples/native_networking/minimqtt_adafruitio_native_networking.py" and modified it to connect to HiveMQ.
It requires tls, so besides changing wifi and mqtt credentials, I also added the is_ssl = True flag.
I can connect but after the loop is called once, the connection fails with an empty Exception:
Traceback (most recent call last):
File "", line 69, in
File "/lib/adafruit_minimqtt/adafruit_minimqtt.py", line 1050, in loop
File "/lib/adafruit_minimqtt/adafruit_minimqtt.py", line 1078, in _wait_for_msg
MMQTTException:
Digging deeper into it, and changing line 1078 to just "raise", gives a bit more insights:
Traceback (most recent call last):
File "", line 69, in
File "/lib/adafruit_minimqtt/adafruit_minimqtt.py", line 1050, in loop
File "/lib/adafruit_minimqtt/adafruit_minimqtt.py", line 1073, in _wait_for_msg
File "/lib/adafruit_minimqtt/adafruit_minimqtt.py", line 1160, in _sock_exact_recv
OSError: -116
But not much more.
EDIT: I use RPi Pico WS, tested with CircuitPython 8 and 9, also the official release libraries and the most recent minimqtt code from here.
Connecting to a local broker without credentials works fine.
The full code of the test script is:
The log output is:
The text was updated successfully, but these errors were encountered: