Adafruit_CircuitPython_MiniMQTT
Adafruit_CircuitPython_MiniMQTT copied to clipboard
consider setting default non zero value for timeout in loop()
Looks like the timeout=0 in loop() caused some unexpected behavior https://forums.adafruit.com/viewtopic.php?p=954996#p954996. Maybe it should be considered setting this to non-zero default ?
It looks like in the sockets that timeout=0 is blocking, which seems different than how CPython handles it. It may be worth changing that to keep compatibility, I'll try to remember to bring it up at the next CircuitPython weekly meeting.
Marking as a bug for now because of the above, and at the very least it doesn't do what the docstring says (0 should be non-blocking according to that).
see my comment in https://github.com/adafruit/Adafruit_CircuitPython_MiniMQTT/issues/138#issuecomment-2316163967 as it might solve the issue with timeout=0
This issue can be closed given the default timeout in loop() was changed to 1 in 3ec6d2c5.