Switchbot integration cannot be added

when adding the integration, it just fails with unexpected error


2022-07-30 06:03:39 ERROR (MainThread) [homeassistant.components.switchbot.config_flow] Unexpected exception stderr

23:03:39 Traceback (most recent call last): stderr

23:03:39 File “/usr/src/homeassistant/homeassistant/components/switchbot/config_flow.py”, line 89, in async_step_user stderr

23:03:39 self._discovered_devices = await self._get_switchbots() stderr

23:03:39 File “/usr/src/homeassistant/homeassistant/components/switchbot/config_flow.py”, line 55, in _get_switchbots stderr

23:03:39 _btle_adv_data = await _btle_connect() stderr

23:03:39 File “/usr/src/homeassistant/homeassistant/components/switchbot/config_flow.py”, line 34, in _btle_connect stderr

23:03:39 switchbot_devices = await GetSwitchbotDevices().discover() stderr

23:03:39 File “/usr/local/lib/python3.10/site-packages/switchbot/init.py”, line 167, in discover stderr

23:03:39 await devices.start() stderr

23:03:39 File “/usr/local/lib/python3.10/site-packages/bleak/backends/bluezdbus/scanner.py”, line 88, in start stderr

23:03:39 self._bus = await MessageBus(bus_type=BusType.SYSTEM).connect() stderr

23:03:39 File “/usr/local/lib/python3.10/site-packages/dbus_next/aio/message_bus.py”, line 122, in init stderr

23:03:39 super().init(bus_address, bus_type, ProxyObject) stderr

23:03:39 File “/usr/local/lib/python3.10/site-packages/dbus_next/message_bus.py”, line 85, in init stderr

23:03:39 self._setup_socket() stderr

23:03:39 File “/usr/local/lib/python3.10/site-packages/dbus_next/message_bus.py”, line 575, in _setup_socket stderr

23:03:39 raise err stderr

23:03:39 File “/usr/local/lib/python3.10/site-packages/dbus_next/message_bus.py”, line 548, in _setup_socket stderr

23:03:39 self._sock.connect(filename) stderr

23:03:39 FileNotFoundError: [Errno 2] No such file or directory

anybody encountering the same?

It’s broken. I just tried installing the SwitchBot Integration and got the same error.

Try this thread, this is how I got mine operational without an integration (well with REST API integration):

FWIW, it appears this is a known issue and was literally just fixed an hour after you posted this:

Now we just need to wait for an HA Core update that includes it.

wow thanks for heads up Rob.
I’ll wait until this gets included in the next release.

cheers mate!

2002.8, finally, the integration can be added… switchbot bot autodiscovered too. testing now…

it works now, but there’s a lot of delay from the command to the bot moviment…

any setting to change?!