Skip to content

Conversation

bdraco
Copy link
Member

@bdraco bdraco commented Jul 29, 2022

This will work with 0.14.3 as well

There is also a performance fix in #54

I merged the performance fix from #52 into #54 and closed #52 since it would conflict

@pascalwinters
Copy link

@Danielhiversen can you merge this PR, so we can test it in the latest HA beta? The SwitchBot integration is broken now because of the Bleak version.

@Danielhiversen Danielhiversen merged commit ed87807 into sblibs:master Jul 31, 2022
@DarKOrange75
Copy link

DarKOrange75 commented Aug 3, 2022

Integration broken for me after upgrade to 2022.8.0 public release :-(

Logger: switchbot
Source: /usr/local/lib/python3.10/site-packages/switchbot/init.py:363
First occurred: 21:01:06 (12 occurrences)
Last logged: 21:15:13

Switchbot communication failed. Stopping trying
Traceback (most recent call last):
File "/usr/local/lib/python3.10/site-packages/bleak_retry_connector/init.py", line 85, in establish_connection
await client.connect(timeout=BLEAK_TIMEOUT)
File "/usr/local/lib/python3.10/site-packages/bleak/backends/bluezdbus/client.py", line 167, in connect
assert_reply(reply)
File "/usr/local/lib/python3.10/site-packages/bleak/backends/bluezdbus/utils.py", line 22, in assert_reply
raise BleakDBusError(reply.error_name, reply.body)
bleak.exc.BleakDBusError: [org.freedesktop.DBus.Error.UnknownObject] Method "Connect" with signature "" on interface "org.bluez.Device1" doesn't exist

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/usr/local/lib/python3.10/site-packages/switchbot/init.py", line 360, in _sendcommand
return await self._send_command_locked(key, command)
File "/usr/local/lib/python3.10/site-packages/switchbot/init.py", line 383, in _send_command_locked
client = await establish_connection(
File "/usr/local/lib/python3.10/site-packages/bleak_retry_connector/init.py", line 117, in establish_connection
_raise_if_needed(name, exc)
File "/usr/local/lib/python3.10/site-packages/bleak_retry_connector/init.py", line 78, in _raise_if_needed
raise BleakConnectionError(msg) from exc
bleak_retry_connector.BleakConnectionError: F4-2E-C3-26-3A-6E (F4:2E:C3:26:3A:6E): Failed to connect: [org.freedesktop.DBus.Error.UnknownObject] Method "Connect" with signature "" on interface "org.bluez.Device1" doesn't exist

@bdraco
Copy link
Member Author

bdraco commented Aug 3, 2022

org.bluez.Device1 doesn't exist means the bluetooth adapter can't be found.

Try restarting the host and make sure bluetoothctl can see the adapter.

This isn't the place to get bluetooth support though

@sblibs sblibs locked as resolved and limited conversation to collaborators Aug 3, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants