mirror of
https://github.com/MarekWo/mc-webui.git
synced 2026-08-02 15:03:25 +02:00
a92b505975
BlueZ auto-reconnects trusted BLE devices, which races with bleak's connect and causes 'failed to discover services' or 'Notify acquired'. Now we temporarily untrust the device before connecting (to prevent BlueZ from auto-reconnecting during the handoff), then re-trust it after bleak has established its GATT session. Also adds _ble_retrust() helper to re-trust the device in a finally block, ensuring the bond is maintained even on connection failure. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>