Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HA 2022.8.5 + SkyKettle v2.0 Не сопрягается с устройством #26

Open
Nemiroff opened this issue Aug 16, 2022 · 10 comments

Comments

@Nemiroff
Copy link

Nemiroff commented Aug 16, 2022

Home Assistant 2022.8.5

2022-08-16 15:35:19.005 DEBUG (MainThread) [custom_components.skykettle.config_flow] Device found: 0C:8C:DC:23:74:CD - 0C-8C-DC-23-74-CD
2022-08-16 15:35:19.006 DEBUG (MainThread) [custom_components.skykettle.config_flow] Device found: 64:90:C1:71:5F:E7 - 64-90-C1-71-5F-E7
2022-08-16 15:35:42.324 INFO (MainThread) [custom_components.skykettle.skykettle] Kettle model: RK-M171S
2022-08-16 15:35:42.325 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Updating
2022-08-16 15:35:42.326 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connecting to the Kettle...
2022-08-16 15:35:52.733 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connected to the Kettle
2022-08-16 15:35:52.803 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Subscribed to RX
2022-08-16 15:35:52.804 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Writing command ff, data: [e8 c4 e0 9e f8 76 b2 4b]
2022-08-16 15:35:52.936 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Received: 00
2022-08-16 15:35:52.937 DEBUG (MainThread) [custom_components.skykettle.skykettle] Auth: ok=False
2022-08-16 15:35:52.938 ERROR (MainThread) [custom_components.skykettle.kettle_connection] Auth failed. You need to enable pairing mode on the kettle.
2022-08-16 15:35:52.976 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Disconnected
2022-08-16 15:35:52.979 INFO (MainThread) [custom_components.skykettle.kettle_connection] Stopped.
2022-08-16 15:35:55.072 INFO (MainThread) [custom_components.skykettle.skykettle] Kettle model: RK-M171S
2022-08-16 15:35:55.073 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Updating
2022-08-16 15:35:55.074 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connecting to the Kettle...
2022-08-16 15:35:55.124 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] EOFError: , retry #1
2022-08-16 15:35:55.627 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Updating
2022-08-16 15:35:55.628 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connecting to the Kettle.
@ClusterM
Copy link
Owner

Чайник в этот момент точно в режиме сопряжения? Он не принимает ключ.

@Nemiroff
Copy link
Author

Nemiroff commented Aug 16, 2022

Конечно. Не в первый раз же. Откат до 1.7 не помогает, помог откат HA до 2022.8.1 Так что скорее всего проблема в HA, нежели в компоненте

@Nemiroff Nemiroff changed the title v2.0 Не сопрягается с устройством HA 2022.8.5 + SkyKettle v2.0 Не сопрягается с устройством Aug 16, 2022
@ClusterM
Copy link
Owner

Странно.

@Leon-1409
Copy link

Leon-1409 commented Aug 16, 2022

+1, после обновления до 2.0 теряет сопряжение. HA 2022.8.5. Но мне, в отличии от Nemiroff, откат до 1.7 помог
Итак, при обновлении с 1.7 до 2.0 связь теряется - если из интеграций удалить чайник и попробовать добавить снова, то вылезает сообщение
"Не могу подключиться к чайнику. Пожалуйста, убедитесь, что он стоит на подставке, включен в розетку, утилите "hatttool" предоставлены права (смотрите инструкцию), и официальное приложение сейчас не подключено к чайнику."

Удалил 2.0, откатился до 1.7 - всё норм, добавляется. Обновляюсь с 1.7 до 2.0 - ошибка с отвалом чайника повторяется
Снова удаление 2.0 и откат 1.7 - и снова всё нормально работает (хотя в последний раз через Ж сопрягалось, но всё же сопряжение установилось)

UPDATE: Просмотрел другие ветки обсуждений - проблема аналогична багу из "Connection issue after upgrade to 1.4". Откатился на 1.7, так что логи с проблемой не предоставлю (НО! если будет необходимо, то снова всё повторю)
P.S. Чайник RK-G210S

@c1tru55
Copy link

c1tru55 commented Aug 17, 2022

при обновлении до аналогичных версий существующее устройство (RK-M171) отвалилось (хотя и раньше не работало):

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 357, in async_setup
    result = await component.async_setup_entry(hass, self)
  File "/config/custom_components/skykettle/__init__.py", line 32, in async_setup_entry
    kettle = KettleConnection(
  File "/config/custom_components/skykettle/kettle_connection.py", line 24, in __init__
    super().__init__(model)
  File "/config/custom_components/skykettle/skykettle.py", line 116, in __init__
    raise SkyKettleError("Unknown kettle model")
custom_components.skykettle.skykettle.SkyKettleError: Unknown kettle model

потом удалил интеграцию, и при попытке добавления новой сразу получаю сообщение Неизвестная ошибка, смотрите логи.:

Traceback (most recent call last): File "/config/custom_components/skykettle/config_flow.py", line 74, in async_step_scan for device in scanner.discovered_devices: File "/usr/src/homeassistant/homeassistant/components/bluetooth/models.py", line 172, in discovered_devices return HA_BLEAK_SCANNER.discovered_devices File "/usr/local/lib/python3.10/site-packages/bleak/backends/bluezdbus/scanner.py", line 183, in discovered_devices for path, props in self._devices.items(): AttributeError: 'HaBleakScanner' object has no attribute '_devices'

@ClusterM
Copy link
Owner

при обновлении до аналогичных версий существующее устройство (RK-M171) отвалилось (хотя и раньше не работало):

Убедитесь, что интеграция Bluetooth установлена и работает.

@c1tru55
Copy link

c1tru55 commented Aug 17, 2022

Убедитесь, что интеграция Bluetooth установлена и работает.

Помогло, спасибо.

@ClusterM
Copy link
Owner

+1, после обновления до 2.0 теряет сопряжение. HA 2022.8.5. Но мне, в отличии от Nemiroff, откат до 1.7 помог Итак, при обновлении с 1.7 до 2.0 связь теряется - если из интеграций удалить чайник и попробовать добавить снова, то вылезает сообщение "Не могу подключиться к чайнику. Пожалуйста, убедитесь, что он стоит на подставке, включен в розетку, утилите "hatttool" предоставлены права (смотрите инструкцию), и официальное приложение сейчас не подключено к чайнику."

Удалил 2.0, откатился до 1.7 - всё норм, добавляется. Обновляюсь с 1.7 до 2.0 - ошибка с отвалом чайника повторяется Снова удаление 2.0 и откат 1.7 - и снова всё нормально работает (хотя в последний раз через Ж сопрягалось, но всё же сопряжение установилось)

UPDATE: Просмотрел другие ветки обсуждений - проблема аналогична багу из "Connection issue after upgrade to 1.4". Откатился на 1.7, так что логи с проблемой не предоставлю (НО! если будет необходимо, то снова всё повторю) P.S. Чайник RK-G210S

Похоже, что поддержка Bluetooth в новом HA пока ещё сыровата. Да, логи было бы здорово посмотреть, если не сложно.

@Leon-1409
Copy link

Похоже, что поддержка Bluetooth в новом HA пока ещё сыровата. Да, логи было бы здорово посмотреть, если не сложно.

Обновился - решил посмотреть, будет ли что-то новое в HA 2022.9.1. В общем, нет, проблема осталась. Логи прикрепил ниже. Сейчас обратно откачусь до 1.7, а то интеграция спамит нещадно

2022-09-11 19:42:53.335 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, BleakDBusError: [org.bluez.Error.Failed] Input/output error 2022-09-11 19:42:59.377 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, BleakDBusError: [org.bluez.Error.Failed] Input/output error 2022-09-11 19:43:05.411 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, BleakDBusError: [org.bluez.Error.Failed] Input/output error 2022-09-11 19:43:11.457 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, BleakDBusError: [org.bluez.Error.Failed] Input/output error 2022-09-11 19:43:17.495 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, BleakDBusError: [org.bluez.Error.Failed] Input/output error 2022-09-11 19:43:23.567 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, BleakDBusError: [org.bluez.Error.Failed] Input/output error 2022-09-11 19:43:29.626 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, BleakDBusError: [org.bluez.Error.Failed] Input/output error 2022-09-11 19:43:35.686 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, BleakDBusError: [org.bluez.Error.Failed] Input/output error 2022-09-11 19:43:41.761 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, BleakDBusError: [org.bluez.Error.Failed] Input/output error 2022-09-11 19:43:47.808 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, BleakDBusError: [org.bluez.Error.Failed] Input/output error 2022-09-11 19:43:53.850 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, BleakDBusError: [org.bluez.Error.Failed] Input/output error

@DrDen666
Copy link

DrDen666 commented Dec 4, 2022

Home Assistant 2022.11.5
SkyKettle v2.1
Не добавляет чайник в интеграцию
`2022-12-04 23:16:41.067 INFO (MainThread) [custom_components.skykettle.skykettle] Kettle model: RK-G200S
2022-12-04 23:16:41.067 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Updating
2022-12-04 23:16:41.068 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connecting to the Kettle...
2022-12-04 23:16:51.072 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] TimeoutError: , retry #1
2022-12-04 23:16:51.573 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Updating
2022-12-04 23:16:51.574 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connecting to the Kettle...
2022-12-04 23:17:01.577 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] TimeoutError: , retry #2
2022-12-04 23:17:02.078 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Updating
2022-12-04 23:17:02.079 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connecting to the Kettle...
2022-12-04 23:17:12.084 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, TimeoutError:
2022-12-04 23:17:12.089 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/bluetooth/models.py", line 306, in connect
return await super().connect(**kwargs)
File "/usr/local/lib/python3.10/site-packages/bleak/init.py", line 471, in connect
return await self._backend.connect(**kwargs)
File "/usr/local/lib/python3.10/site-packages/bleak/backends/bluezdbus/client.py", line 172, in connect
reply = await self._bus.call(
File "/usr/local/lib/python3.10/site-packages/dbus_fast/aio/message_bus.py", line 370, in call
await future
asyncio.exceptions.CancelledError
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.10/asyncio/tasks.py", line 456, in wait_for
return fut.result()
asyncio.exceptions.CancelledError
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/config/custom_components/skykettle/kettle_connection.py", line 153, in update
await self._connect_if_need()
File "/config/custom_components/skykettle/kettle_connection.py", line 133, in _connect_if_need
raise ex
File "/config/custom_components/skykettle/kettle_connection.py", line 128, in _connect_if_need
await self._connect()
File "/config/custom_components/skykettle/kettle_connection.py", line 94, in _connect
await asyncio.wait_for(
File "/usr/local/lib/python3.10/asyncio/tasks.py", line 458, in wait_for
raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError

2022-12-04 23:17:12.090 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Updating
2022-12-04 23:17:12.090 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connecting to the Kettle...
2022-12-04 23:17:22.094 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] TimeoutError: , retry #1
2022-12-04 23:17:22.596 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Updating
2022-12-04 23:17:22.596 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connecting to the Kettle...
2022-12-04 23:17:32.601 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] TimeoutError: , retry #2
2022-12-04 23:17:33.104 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Updating
2022-12-04 23:17:33.105 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connecting to the Kettle...
2022-12-04 23:17:43.114 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, TimeoutError:
2022-12-04 23:17:43.120 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/bluetooth/models.py", line 306, in connect
return await super().connect(**kwargs)
File "/usr/local/lib/python3.10/site-packages/bleak/init.py", line 471, in connect
return await self._backend.connect(**kwargs)
File "/usr/local/lib/python3.10/site-packages/bleak/backends/bluezdbus/client.py", line 172, in connect
reply = await self._bus.call(
File "/usr/local/lib/python3.10/site-packages/dbus_fast/aio/message_bus.py", line 370, in call
await future
asyncio.exceptions.CancelledError
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.10/asyncio/tasks.py", line 456, in wait_for
return fut.result()
asyncio.exceptions.CancelledError
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/config/custom_components/skykettle/kettle_connection.py", line 153, in update
await self._connect_if_need()
File "/config/custom_components/skykettle/kettle_connection.py", line 133, in _connect_if_need
raise ex
File "/config/custom_components/skykettle/kettle_connection.py", line 128, in _connect_if_need
await self._connect()
File "/config/custom_components/skykettle/kettle_connection.py", line 94, in _connect
await asyncio.wait_for(
File "/usr/local/lib/python3.10/asyncio/tasks.py", line 458, in wait_for
raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError

2022-12-04 23:17:43.121 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Updating
2022-12-04 23:17:43.121 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connecting to the Kettle...
2022-12-04 23:17:53.128 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] TimeoutError: , retry #1
2022-12-04 23:17:53.631 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Updating
2022-12-04 23:17:53.631 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connecting to the Kettle...
2022-12-04 23:18:03.639 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] TimeoutError: , retry #2
2022-12-04 23:18:04.141 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Updating
2022-12-04 23:18:04.142 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Connecting to the Kettle...
2022-12-04 23:18:14.146 WARNING (MainThread) [custom_components.skykettle.kettle_connection] Can't update status, TimeoutError:
2022-12-04 23:18:14.149 DEBUG (MainThread) [custom_components.skykettle.kettle_connection] Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/bluetooth/models.py", line 306, in connect
return await super().connect(**kwargs)
File "/usr/local/lib/python3.10/site-packages/bleak/init.py", line 471, in connect
return await self._backend.connect(**kwargs)
File "/usr/local/lib/python3.10/site-packages/bleak/backends/bluezdbus/client.py", line 172, in connect
reply = await self._bus.call(
File "/usr/local/lib/python3.10/site-packages/dbus_fast/aio/message_bus.py", line 370, in call
await future
asyncio.exceptions.CancelledError
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.10/asyncio/tasks.py", line 456, in wait_for
return fut.result()
asyncio.exceptions.CancelledError
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/config/custom_components/skykettle/kettle_connection.py", line 153, in update
await self._connect_if_need()
File "/config/custom_components/skykettle/kettle_connection.py", line 133, in _connect_if_need
raise ex
File "/config/custom_components/skykettle/kettle_connection.py", line 128, in _connect_if_need
await self._connect()
File "/config/custom_components/skykettle/kettle_connection.py", line 94, in _connect
await asyncio.wait_for(
File "/usr/local/lib/python3.10/asyncio/tasks.py", line 458, in wait_for
raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError

2022-12-04 23:18:14.149 INFO (MainThread) [custom_components.skykettle.kettle_connection] Stopped.`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants