Thanks for the tip! In that case: have a good holiday and I’ll run the latest (test) version first than.
Just made some small changes to the branch:
- Small changes to the Config Flow strings (not visible when you use the custom component PR method)
- Validate if Developer Mode is turned on, after login
-
no_such_token
error would be raised on every error, now you will see the original error (e.g. cannot connect).
Feel free to test the latest version :).
When I was using the cloud api version, I had created an automation check in Node-RED to check if one of my covers are unavailable. When that was the case I get a push notification.
I get those messages on regular base.
Since 3 days I’m now using the test local api version in my production environment. The unavailable check is still running. And what I noticed is that the covers are still sometimes unavailable.
So does anybody else have unavailable entities of the Tahoma Switch with the local api at some times?
In my case (since 25-07) the covers are 7x unavailable. My Hue lights don’t show unavailable state and there are connected on the same network switch. Also my Tahoma switch is connected by ethernet.
Hi Mick, where can I download this latest version? (I’m using the custom component PR method)
And how can I log the information of this custom component?
logger:
default: debug
logs:
custom_components.tahoma: debug
If your use the PR integration, go to the integration panel, click on the 3 dots on the device, and reload, see screenshot, this should repull the pull request to latest version. then just restart HA.
I have tried it, but how can I see if i really have the new code?
(I used this method: Overkiz API and Somfy API - Feature Requests - Home Assistant Community (home-assistant.io))
So I have copied the overkiz folder to the custom components folder.
[UPDATE] The official Somfy app kept notifying me the Tahoma Switch got disconnected. This got me thinking: Maybe my connection isn’t stable enough for the Tahoma Switch. I placed it for 12 hours on a different spot and no more disconnections! This might help others as well regarding the ‘unavailable’ states. These are gone now.
BUT: My Garage door isn’t getting the proper states still when my wife uses our oldskool ‘IO key’. Sometimes HA senses the door is being opened, but after closing within a minute the close states isn’t in my logs. I’m going to setup a quick REST dev setup soon for myself to test if the states are correct without this plugin to test. . After running the API via CURL everything is fine, but there is a bug regarding garage Doors and refreshing the closed state…
====
Ok, installed via PR custom component. Installation went flawless (although had to double read my PIN was necessary in the gateway URL.
After a couple of hours I’ve seen a lot of ‘Garage became unavailable’ and ‘Garage Identify became unavailable’. This is the same behaviour for my sun cover. Any idea what’s happening?
You are using the switch on wifi?
I use it with ethernet and get sometimes an unavailable state.
Not sure actually where this is coming from. I have seen this in the past, but I thought it was resolved in the last versions. Unfortunately the local API on my TaHoma Switch isn’t functional anymore, so I will have to wait for support…
Will keep an eye out for this issue, and see if I otherwise can add additional logging for this.
whats wrong with Local API on your Tahoma Switch ? Hardware issue ?
I use WiFi (which is default) indeed. I can’t use Ethernet unless I’ll expand with a special adapter.
No clue. It is connected via WiFi and I can access it in the TaHoma app, however I can’t ping the local API. It seems something is not working…
have you tried disabling Developer access and re-enable it?
well my Virgin Media Fibre BB is down yet again, at least it gave me chnace to test this integration a real world test HAHA, and it PASSED
That is not possible. I wasn’t able to factory reset my TaHoma Switch, but I have had more issues with developer mode on my box in the past. My parents TaHoma v2 works like a charm for dev mode.
For the tahoma V2 you can click on the button … but no action is followed
All working fine over here
I do seem to be getting lots of these errors in the log.
This error originated from a custom integration.
Logger: custom_components.overkiz
Source: helpers/update_coordinator.py:229
Integration: Custom Overkiz PR#71644
First occurred: 29 July 2023 at 14:17:58 (74 occurrences)
Last logged: 10:41:40
Error requesting device events data: Cannot connect to host gateway-2024-6137-2105.local:8443 ssl:default [Try again]
any ideas whats causing them ?, I also have an automation fail last night due to not beenable to close my bedrrom shade.
This error originated from a custom integration.
Logger: homeassistant.helpers.script.andys_bedroom_window_shade
Source: custom_components/overkiz/executor.py:91
Integration: Custom Overkiz PR#71644
First occurred: 2 August 2023 at 21:06:09 (1 occurrences)
Last logged: 2 August 2023 at 21:06:09
Andys Bedroom Window Shade: Error executing script. Unexpected error for call_service at pos 2: Cannot connect to host gateway-2024-6137-2105.local:8443 ssl:default [Try again]
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/aiohttp/connector.py", line 1155, in _create_direct_connection
hosts = await asyncio.shield(host_resolved)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/connector.py", line 1155, in _create_direct_connection
hosts = await asyncio.shield(host_resolved)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/connector.py", line 874, in _resolve_host
addrs = await self._resolver.resolve(host, port, family=self._family)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/resolver.py", line 33, in resolve
infos = await self._loop.getaddrinfo(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/asyncio/base_events.py", line 867, in getaddrinfo
return await self.run_in_executor(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/socket.py", line 962, in getaddrinfo
for res in _socket.getaddrinfo(host, port, family, type, proto, flags):
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
socket.gaierror: [Errno -3] Try again
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 468, in _async_step
await getattr(self, handler)()
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 703, in _async_call_service_step
response_data = await self._async_run_long_action(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 665, in _async_run_long_action
return long_task.result()
^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 1965, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2005, in _execute_service
return await cast(
^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 235, in handle_service
return await service.entity_service_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 848, in entity_service_call
response_data = task.result() # pop exception if have
^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1192, in async_request_call
return await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 892, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/config/custom_components/overkiz/cover_entities/vertical_cover.py", line 106, in async_close_cover
await self.executor.async_execute_command(command)
File "/config/custom_components/overkiz/executor.py", line 91, in async_execute_command
exec_id = await self.coordinator.client.execute_command(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/backoff/_async.py", line 151, in retry
ret = await target(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/backoff/_async.py", line 151, in retry
ret = await target(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyoverkiz/client.py", line 622, in execute_command
response: str = await self.execute_commands(device_url, [command], label)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/backoff/_async.py", line 151, in retry
ret = await target(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyoverkiz/client.py", line 650, in execute_commands
response: dict = await self.__post("exec/apply", payload)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyoverkiz/client.py", line 846, in __post
async with self.session.post(
File "/usr/local/lib/python3.11/site-packages/aiohttp/client.py", line 1141, in __aenter__
self._resp = await self._coro
^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/client.py", line 536, in _request
conn = await self._connector.connect(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/connector.py", line 540, in connect
proto = await self._create_connection(req, traces, timeout)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/connector.py", line 901, in _create_connection
_, proto = await self._create_direct_connection(req, traces, timeout)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/connector.py", line 1169, in _create_direct_connection
raise ClientConnectorError(req.connection_key, exc) from exc
aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host gateway-2024-6137-2105.local:8443 ssl:default [Try again]
Logger: homeassistant.components.automation.evening_sunset
Source: custom_components/overkiz/executor.py:91
Integration: Automation (documentation, issues)
First occurred: 2 August 2023 at 21:06:09 (2 occurrences)
Last logged: 2 August 2023 at 21:06:09
Evening: Error executing script. Unexpected error for call_service at pos 1: Cannot connect to host gateway-2024-6137-2105.local:8443 ssl:default [Try again]
While executing automation automation.evening_sunset
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/aiohttp/connector.py", line 1155, in _create_direct_connection
hosts = await asyncio.shield(host_resolved)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/connector.py", line 1155, in _create_direct_connection
hosts = await asyncio.shield(host_resolved)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/connector.py", line 874, in _resolve_host
addrs = await self._resolver.resolve(host, port, family=self._family)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/resolver.py", line 33, in resolve
infos = await self._loop.getaddrinfo(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/asyncio/base_events.py", line 867, in getaddrinfo
return await self.run_in_executor(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/socket.py", line 962, in getaddrinfo
for res in _socket.getaddrinfo(host, port, family, type, proto, flags):
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
socket.gaierror: [Errno -3] Try again
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 468, in _async_step
await getattr(self, handler)()
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 703, in _async_call_service_step
response_data = await self._async_run_long_action(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 665, in _async_run_long_action
return long_task.result()
^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 1965, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2005, in _execute_service
return await cast(
^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 235, in handle_service
return await service.entity_service_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 848, in entity_service_call
response_data = task.result() # pop exception if have
^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1192, in async_request_call
return await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 892, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/scene/__init__.py", line 114, in _async_activate
await self.async_activate(**kwargs)
File "/usr/src/homeassistant/homeassistant/components/homeassistant/scene.py", line 334, in async_activate
await async_reproduce_state(
File "/usr/src/homeassistant/homeassistant/helpers/state.py", line 115, in async_reproduce_state
await asyncio.gather(
File "/usr/src/homeassistant/homeassistant/helpers/state.py", line 109, in worker
await platform.async_reproduce_states(
File "/usr/src/homeassistant/homeassistant/components/cover/reproduce_state.py", line 125, in async_reproduce_states
await asyncio.gather(
File "/usr/src/homeassistant/homeassistant/components/cover/reproduce_state.py", line 86, in _async_reproduce_state
await hass.services.async_call(
File "/usr/src/homeassistant/homeassistant/core.py", line 1965, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2005, in _execute_service
return await cast(
^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 235, in handle_service
return await service.entity_service_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 848, in entity_service_call
response_data = task.result() # pop exception if have
^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1192, in async_request_call
return await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 892, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/template/cover.py", line 358, in async_close_cover
await self.async_run_script(self._close_script, context=self._context)
File "/usr/src/homeassistant/homeassistant/helpers/template_entity.py", line 444, in async_run_script
await script.async_run(
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 1569, in async_run
return await asyncio.shield(run.async_run())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 420, in async_run
await self._async_step(log_exceptions=False)
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 470, in _async_step
self._handle_exception(
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 493, in _handle_exception
raise exception
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 468, in _async_step
await getattr(self, handler)()
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 703, in _async_call_service_step
response_data = await self._async_run_long_action(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 665, in _async_run_long_action
return long_task.result()
^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 1965, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2005, in _execute_service
return await cast(
^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 235, in handle_service
return await service.entity_service_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 848, in entity_service_call
response_data = task.result() # pop exception if have
^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1192, in async_request_call
return await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 892, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/config/custom_components/overkiz/cover_entities/vertical_cover.py", line 106, in async_close_cover
await self.executor.async_execute_command(command)
File "/config/custom_components/overkiz/executor.py", line 91, in async_execute_command
exec_id = await self.coordinator.client.execute_command(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/backoff/_async.py", line 151, in retry
ret = await target(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/backoff/_async.py", line 151, in retry
ret = await target(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyoverkiz/client.py", line 622, in execute_command
response: str = await self.execute_commands(device_url, [command], label)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/backoff/_async.py", line 151, in retry
ret = await target(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyoverkiz/client.py", line 650, in execute_commands
response: dict = await self.__post("exec/apply", payload)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pyoverkiz/client.py", line 846, in __post
async with self.session.post(
File "/usr/local/lib/python3.11/site-packages/aiohttp/client.py", line 1141, in __aenter__
self._resp = await self._coro
^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/client.py", line 536, in _request
conn = await self._connector.connect(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/connector.py", line 540, in connect
proto = await self._create_connection(req, traces, timeout)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/connector.py", line 901, in _create_connection
_, proto = await self._create_direct_connection(req, traces, timeout)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/connector.py", line 1169, in _create_direct_connection
raise ClientConnectorError(req.connection_key, exc) from exc
aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host gateway-2024-6137-2105.local:8443 ssl:default [Try again]
This means that your Home Assistant instance cannot connect to the gateway. Not sure where the connectivity issue is, but this is not something that I can fix…
However, I should try to see if we at least can retry on this error.
@andyblac, just pushed a new version that should at least better handle/retry these errors. You will still see these errors though if it cannot connect multiple times.