Menu główne

Natywna integracja z Home Assistant (komponent) 2.1

Zaczęty przez admin, Wrzesień 14, 2020, 11:04:03

Poprzedni wątek - Następny wątek

SebiCo

#270
ok juz wiem co się zadziało
Podmieniłem oczywiście w custom, ale stąd nie chce się uruchomic i wystartowała z wbudowanej (czego nie zauważyłem).
Teraz usunąłem wbudowaną i z custom integracja nie uruchamia sie w ogóle :(
Przy próbie instalacji mam błąd
Błąd
Nie udało się wczytać interfejsu konfiguracji: [object Object]


w logah

Logger: homeassistant.components.websocket_api.http.connection
Source: loader.py:642
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 13:26:06 (1 occurrences)
Last logged: 13:26:06

[2668703832] Error handling message: Unknown error
Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/websocket_api/decorators.py", line 27, in _handle_async_response
    await func(hass, connection, msg)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/frontend/__init__.py", line 683, in websocket_get_translations
    resources = await async_get_translations(
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/helpers/translation.py", line 311, in async_get_translations
    cached = await cache.async_fetch(language, category, components)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/helpers/translation.py", line 221, in async_fetch
    await self._async_load(language, components_to_load)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/helpers/translation.py", line 236, in _async_load
    for translation_strings in await asyncio.gather(
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/helpers/translation.py", line 156, in async_get_component_strings
    await gather_with_concurrency(
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/util/async_.py", line 185, in gather_with_concurrency
    return await gather(
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/util/async_.py", line 183, in sem_task
    return await task
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/loader.py", line 614, in async_get_integration
    integration = await _async_get_integration(hass, domain)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/loader.py", line 642, in _async_get_integration
    raise IntegrationNotFound(domain)
homeassistant.loader.IntegrationNotFound: Integration 'extalife' not found.



Logger: homeassistant.config_entries
Source: config_entries.py:726
First occurred: 13:27:14 (2 occurrences)
Last logged: 13:30:59

Cannot find integration extalife
  •  

admin

Hmm, może być tak, że AIS nadal próbuje ładować integrację wbudowaną z wewnętrznego folderu a tam nic nie ma i failuje. Spróbuj w takim razie skopiować pliki z githuba do wewnętrznego folderu integracji, restart i zobacz ponownie. Takich powżnych problemów ze startem nie przewiduję. Na moim HA dev nic takiego nie miało miejsca a potencjalne problemy mogą się wydarzyć dopiero podczas pracy integracji a nie już przy ładowaniu. Nie ma nawet problemu ze składnią, tylko wygląda jakby w folderze integracji nie było plików, a AIS chce je załadować, bo ma takie config entry.
Elementy systemu, których używam: 3xSRP-22, 5xRDP-21, 3xROP-22, 4x ROP-21, 1xP-456/36, 1xRNK-24, 3x RNP-21, 1xRCT-22, aplikacja na Android oraz iOS + Home Assistant
  •  

SebiCo

Tak dokładnie zrobiłem i działa :)
Ale co ciekawe "stara" integracja działa w custom bez problemu, a "nowa" tylko w wewnętrznym

Oczywiście serwisy connect i disconnect działają :D
  •  

admin

Cytat: SebiCo w Luty 21, 2022, 14:26:21
Tak dokładnie zrobiłem i działa :)
Ale co ciekawe "stara" integracja działa w custom bez problemu, a "nowa" tylko w wewnętrznym

Oczywiście serwisy connect i disconnect działają :D

Nie potrafię tego wytłumaczyć. W nowej wersji nie ma niczego co mogłoby wspłynąć na to, że działa albo jako wbudowana albo jako custom. Tutaj żadnych zmian nie było, a u mnie na HA dev mam ją właśnie jako custom_component :)
Elementy systemu, których używam: 3xSRP-22, 5xRDP-21, 3xROP-22, 4x ROP-21, 1xP-456/36, 1xRNK-24, 3x RNP-21, 1xRCT-22, aplikacja na Android oraz iOS + Home Assistant
  •  

SebiCo

Specjalnie jeszcze raz sprawdziłem i u mnie nie chce ruszyć z custom, poczekamy zobaczymy jak u innych ;)
  •  

Fantomas

#275
Jeszcze nie wiem, co się stało, ale objaw ten sam przed i po wgraniu nowej wersji integracji (wygląda jak w wątku powyżej, więc będę próbował sobie też poradzić):

Logger: homeassistant.config_entries
Source: components/extalife/helpers/device.py:7
First occurred: 20:34:10 (1 occurrences)
Last logged: 20:34:10

Error setting up entry efc-01 for extalife
Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/config_entries.py", line 313, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 140, in async_setup_entry
    Core.create(hass, config_entry)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/helpers/core.py", line 40, in create
    inst = Core(config_entry)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/helpers/core.py", line 60, in __init__
    from .device import DeviceManager
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/helpers/device.py", line 7, in <module>
    from homeassistant.components.automation import AutomationActionType, state
ImportError: cannot import name 'state' from 'homeassistant.components.automation' (/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/automation/__init__.py)
Elementy systemu, których używam: HA, EFC-01, 3x ROP-01, 3x ROP-02, RDP-01, ROP-07, RNK-02, 5x RNK-04, RNP-01, P-257/2, 2x ROP-21, 3x ROP-22, 5x RNK-24, RCK-21, 3x RCR-21, RCM-21, 4x RGT-01, urządzenia Zigbee (ZHA), urządzenia WiFi (Tuya).
  •  

Fantomas

Dalej to samo, a podmieniłem pliki z wewnętrznej integracji AIS na te z githuba, wg powyższego opisu powinno być dobrze, a nie jest.
Jednak zawołam "pomocy!".
Elementy systemu, których używam: HA, EFC-01, 3x ROP-01, 3x ROP-02, RDP-01, ROP-07, RNK-02, 5x RNK-04, RNP-01, P-257/2, 2x ROP-21, 3x ROP-22, 5x RNK-24, RCK-21, 3x RCR-21, RCM-21, 4x RGT-01, urządzenia Zigbee (ZHA), urządzenia WiFi (Tuya).
  •  

admin

#277
Cytat: Fantomas w Luty 22, 2022, 22:11:43
Dalej to samo, a podmieniłem pliki z wewnętrznej integracji AIS na te z githuba, wg powyższego opisu powinno być dobrze, a nie jest.
Jednak zawołam "pomocy!".
Na stabilnej (miejmy nadzieję) wersji 2.1.2 też się sypie? Jeśli tak to coś się musiało zmienić ostatnio w HA do czego integracja jeszcze nie jest przystosowana..daj znać.

Przypuszczam że ten błąd pochodzi od automatyzacji która, używa device Automation a nie encji. Przejrzyj automatyzacje jakie masz z urządzeniami Exta Life i jeśli diagnoza się potwierdzi to zmień odwołanie z urządzeń na encje
Elementy systemu, których używam: 3xSRP-22, 5xRDP-21, 3xROP-22, 4x ROP-21, 1xP-456/36, 1xRNK-24, 3x RNP-21, 1xRCT-22, aplikacja na Android oraz iOS + Home Assistant
  •  

Fantomas

#278
Na wersji dostarczonej z AIS:

Logger: homeassistant.config_entries
Source: components/extalife/pyextalife.py:797
First occurred: 22:40:12 (1 occurrences)
Last logged: 22:40:12

Error setting up entry efc-01 for extalife
Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/asyncio/tasks.py", line 492, in wait_for
    fut.result()
asyncio.exceptions.CancelledError

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

Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 793, in async_send_message_await_response
    await asyncio.wait_for(fut, timeout)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/asyncio/tasks.py", line 494, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/config_entries.py", line 313, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 188, in async_setup_entry
    return await initialize(hass, config_entry)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 302, in initialize
    await data.async_start_polling(poll_now=True)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 362, in async_start_polling
    await self.async_execute_status_polling()
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 369, in async_execute_status_polling
    await self._async_update_callback()
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 389, in _async_update_callback
    channels = await self.controller.async_get_channels()
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 466, in async_get_channels
    resp = await self._connection.async_execute_command(cmd, None)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 815, in async_execute_command
    response = await self.async_send_message_await_response(msg, command)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 797, in async_send_message_await_response
    raise TCPConnError("Disconnected while waiting for API response!")
homeassistant.components.extalife.pyextalife.TCPConnError


Na 2.1.2 praktycznie to samo:

Logger: homeassistant.config_entries
Source: components/extalife/pyextalife.py:798
First occurred: 22:51:07 (1 occurrences)
Last logged: 22:51:07

Error setting up entry efc-01 for extalife
Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/asyncio/tasks.py", line 492, in wait_for
    fut.result()
asyncio.exceptions.CancelledError

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

Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 794, in async_send_message_await_response
    await asyncio.wait_for(fut, timeout)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/asyncio/tasks.py", line 494, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/config_entries.py", line 313, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 144, in async_setup_entry
    return await initialize(hass, config_entry)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 248, in initialize
    await data.async_start_polling(poll_now=True)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 308, in async_start_polling
    await self.async_execute_status_polling()
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 315, in async_execute_status_polling
    await self._async_update_callback()
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 335, in _async_update_callback
    channels = await self.controller.async_get_channels()
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 425, in async_get_channels
    resp = await self._connection.async_execute_command(cmd, None)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 818, in async_execute_command
    response = await self.async_send_message_await_response(msg, command)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 798, in async_send_message_await_response
    raise TCPConnError(
homeassistant.components.extalife.pyextalife.TCPConnError
Elementy systemu, których używam: HA, EFC-01, 3x ROP-01, 3x ROP-02, RDP-01, ROP-07, RNK-02, 5x RNK-04, RNP-01, P-257/2, 2x ROP-21, 3x ROP-22, 5x RNK-24, RCK-21, 3x RCR-21, RCM-21, 4x RGT-01, urządzenia Zigbee (ZHA), urządzenia WiFi (Tuya).
  •  

SebiCo

#279
@Fantomas Masz włączoną chmurę?

@admin "rozwiazałem" mój problem z lokalizacją integracji w custom - "podniosłem" w manifest.json wersję do 2.1.4 i jest ok. Nie mam pojęcia dlaczego tak się dzieje, ale wyczytałem na jakimś forum że to może pomóc i pomogło :)
  •  

Fantomas

Cytat: SebiCo w Luty 22, 2022, 22:56:47
Masz włączoną chmurę?
Bez chmury i bez zjadających połączenia notyfikacji. Za to używam na bramce skryptu (poza integracją) do odczytywania stanu głowic. Czyżby ostatnia aktualizacja oprogramowania kontrolera mogła namieszać?
Elementy systemu, których używam: HA, EFC-01, 3x ROP-01, 3x ROP-02, RDP-01, ROP-07, RNK-02, 5x RNK-04, RNP-01, P-257/2, 2x ROP-21, 3x ROP-22, 5x RNK-24, RCK-21, 3x RCR-21, RCM-21, 4x RGT-01, urządzenia Zigbee (ZHA), urządzenia WiFi (Tuya).
  •  

SebiCo

#281
Może tak być, ja niestety musiałem zrezygnować z dodatkowego skryptu bo zajmował dodatkowe połączenie, na które już nie było wolnych slotów i działy się różne dziwne rzeczy. Dla testu zablokuj skrypt i zobacz czy pomoże bo z logów wynika jakbyś właśnie miał problem z połączeniem z kontrolerem.
  •  

admin

Cytat: Fantomas w Luty 22, 2022, 22:44:16
Na wersji dostarczonej z AIS:

Logger: homeassistant.config_entries
Source: components/extalife/pyextalife.py:797
First occurred: 22:40:12 (1 occurrences)
Last logged: 22:40:12

Error setting up entry efc-01 for extalife
Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/asyncio/tasks.py", line 492, in wait_for
    fut.result()
asyncio.exceptions.CancelledError

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

Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 793, in async_send_message_await_response
    await asyncio.wait_for(fut, timeout)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/asyncio/tasks.py", line 494, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/config_entries.py", line 313, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 188, in async_setup_entry
    return await initialize(hass, config_entry)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 302, in initialize
    await data.async_start_polling(poll_now=True)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 362, in async_start_polling
    await self.async_execute_status_polling()
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 369, in async_execute_status_polling
    await self._async_update_callback()
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 389, in _async_update_callback
    channels = await self.controller.async_get_channels()
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 466, in async_get_channels
    resp = await self._connection.async_execute_command(cmd, None)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 815, in async_execute_command
    response = await self.async_send_message_await_response(msg, command)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 797, in async_send_message_await_response
    raise TCPConnError("Disconnected while waiting for API response!")
homeassistant.components.extalife.pyextalife.TCPConnError


Na 2.1.2 praktycznie to samo:

Logger: homeassistant.config_entries
Source: components/extalife/pyextalife.py:798
First occurred: 22:51:07 (1 occurrences)
Last logged: 22:51:07

Error setting up entry efc-01 for extalife
Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/asyncio/tasks.py", line 492, in wait_for
    fut.result()
asyncio.exceptions.CancelledError

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

Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 794, in async_send_message_await_response
    await asyncio.wait_for(fut, timeout)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/asyncio/tasks.py", line 494, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/config_entries.py", line 313, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 144, in async_setup_entry
    return await initialize(hass, config_entry)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 248, in initialize
    await data.async_start_polling(poll_now=True)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 308, in async_start_polling
    await self.async_execute_status_polling()
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 315, in async_execute_status_polling
    await self._async_update_callback()
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/__init__.py", line 335, in _async_update_callback
    channels = await self.controller.async_get_channels()
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 425, in async_get_channels
    resp = await self._connection.async_execute_command(cmd, None)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 818, in async_execute_command
    response = await self.async_send_message_await_response(msg, command)
  File "/data/data/pl.sviete.dom/files/usr/lib/python3.9/site-packages/homeassistant/components/extalife/pyextalife.py", line 798, in async_send_message_await_response
    raise TCPConnError(
homeassistant.components.extalife.pyextalife.TCPConnError

Ale to jest inny problem niż wcześniej. Integracja nie może się tu połączyć z kontrolerem. Brakuje wolnego połączenia. Używasz notyfikacji lub chmury Exta Life?
Elementy systemu, których używam: 3xSRP-22, 5xRDP-21, 3xROP-22, 4x ROP-21, 1xP-456/36, 1xRNK-24, 3x RNP-21, 1xRCT-22, aplikacja na Android oraz iOS + Home Assistant
  •  

admin

A integracja 2.1.2 z GitHub to jest to samo co dostarcza AIS bo oni to biorą z mojego GitHub repo ;)
Elementy systemu, których używam: 3xSRP-22, 5xRDP-21, 3xROP-22, 4x ROP-21, 1xP-456/36, 1xRNK-24, 3x RNP-21, 1xRCT-22, aplikacja na Android oraz iOS + Home Assistant
  •  

Fantomas

Coś tutaj się podle zbiegło: aktualizacja oprogramowania kontrolera, odtworzenie backupu konfiguracji na nim (czasem się konfiguracja rozjeżdża - znikają mi niektóre urządzenia ExtaFree, ale to już inna historia), próba zastosowania wersji beta, być może zwieszające się skrypty... Póki co przywróciłem inny backup kontrolera, wyłączyłem skrypty (żeby nie zjadały połączenia) i większość automatyzacji (bo i tak do przejrzenia i zmiany urządzeń na encje). Póki co wróciło wszystko, oczywiście oprócz odczytu czasu odświeżenia głowic i poziomu otwarcia zaworów (skrypt).

Dalsze prace raczej dopiero w weekend.
Elementy systemu, których używam: HA, EFC-01, 3x ROP-01, 3x ROP-02, RDP-01, ROP-07, RNK-02, 5x RNK-04, RNP-01, P-257/2, 2x ROP-21, 3x ROP-22, 5x RNK-24, RCK-21, 3x RCR-21, RCM-21, 4x RGT-01, urządzenia Zigbee (ZHA), urządzenia WiFi (Tuya).
  •