micropython-lib
micropython-lib copied to clipboard
aioble/device.py: No default timeout for async disconnected() method.
The value for the timeout_ms
optional argument to DeviceConnection.disconnected()
async method is changed from 60000 to None. This way users awaiting a device disconnection using await connection.disconnected()
won't be surprised by a 1 minute timeout. For instance, in the temp_sensor.py
usage example I think it's reasonable to expect the connection to the client to stay open indefinitely.
This does make sense to me, I know a couple of other people this timeout has tripped up too.
I'm not sure if there was a specific intention behind having a timeout here, can you comment @jimmo ?
This also tripped me up and caused a lot of debug time... can this get merged?