v0.3.6
What's changed
- Typed errors:
MadokaErrorbase;PairingRequiredError(carries the attempted proxy sources) when every path refuses the authenticated bond;DeviceUnreachableErrorwhen no BLE path sees the device;ConnectionExceptionnow subclassesMadokaError.is_pairing_error()classifies auth/bond failures from error text (ATT error 0x05, insufficient encryption, pairing failed, BlueZ auth errors); apair()timeout is treated as a pairing failure at the call site. Typed errors propagate out ofstart(); background reconnects record them inconnection.last_error. - Candidate-list connect API:
Controller(..., candidates_callback=...)— orderedBLEDevicepaths (preferred proxy first), per-path pairing classification,connection.connected_sourcereports the winning proxy. Enables sticky-proxy behavior in Home Assistant; without the callback, behavior is unchanged. - Connection robustness: stale disconnect callbacks can no longer clobber a live connection; failed paths are disconnected before trying the next; background tasks are tracked and quiesced by
cleanup();last_errorcleared on any successful connect. - Explicit pairing-timeout message (#3).
ConnectionStatusexported at package level; test suite 16 → 46.
PyPI: https://pypi.org/project/pymadoka-ng/0.3.6/
Full Changelog: v0.3.5...v0.3.6