home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
72.02k stars 30.17k forks source link

HA losing connect with Overkiz frequently while using local API #120021

Open makhlouta opened 3 months ago

makhlouta commented 3 months ago

The problem

The problem started suddenly, the devices go to unavailable state then show up again, below is some logs: 2024-06-20 14:50:43.613 INFO (MainThread) [backoff] Backing off fetch_events(...) for 0.9s (aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host gateway-XXXX-XXXX-XXXX.local:8443 ssl:<ssl.SSLContext object at 0x7f4ed4d0d0> [Invalid argument]) 2024-06-20 14:50:49.755 ERROR (MainThread) [homeassistant.components.overkiz] Error fetching device events data: Failed to connect. 2024-06-20 14:50:49.755 DEBUG (MainThread) [homeassistant.components.overkiz] Finished fetching device events data in 12.281 seconds (success: False) 2024-06-20 14:51:25.629 INFO (MainThread) [backoff] Backing off fetch_events(...) for 0.5s (aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host gateway-XXXX-XXXX-XXXX.local:8443 ssl:<ssl.SSLContext object at 0x7f4ed4d0d0> [Invalid argument]) 2024-06-20 14:51:31.770 DEBUG (MainThread) [homeassistant.components.overkiz] Finished fetching device events data in 12.297 seconds (success: False) 2024-06-20 14:52:07.612 INFO (MainThread) [backoff] Backing off fetch_events(...) for 0.8s (aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host gateway-XXXX-XXXX-XXXX.local:8443 ssl:<ssl.SSLContext object at 0x7f4ed4d0d0> [Invalid argument]) 2024-06-20 14:52:13.755 DEBUG (MainThread) [homeassistant.components.overkiz] Finished fetching device events data in 12.280 seconds (success: False) 2024-06-20 14:52:49.629 INFO (MainThread) [backoff] Backing off fetch_events(...) for 0.2s (aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host gateway-XXXX-XXXX-XXXX.local:8443 ssl:<ssl.SSLContext object at 0x7f4ed4d0d0> [Invalid argument]) 2024-06-20 14:52:55.770 DEBUG (MainThread) [homeassistant.components.overkiz] Finished fetching device events data in 12.296 seconds (success: False) 2024-06-20 14:53:31.614 INFO (MainThread) [backoff] Backing off fetch_events(...) for 0.9s (aiohttp.client_exceptions.ClientConnectorError: Cannot connect to host gateway-XXXX-XXXX-XXXX.local:8443 ssl:<ssl.SSLContext object at 0x7f4ed4d0d0> [Invalid argument]) 2024-06-20 14:53:37.754 DEBUG (MainThread) [homeassistant.components.overkiz] Finished fetching device events data in 12.279 seconds (success: False)

and

`Logger: homeassistant.components.overkiz Source: helpers/update_coordinator.py:344 integration: Overkiz (documentation, issues) First occurred: June 18, 2024 at 9:18:23 PM (796 occurrences) Last logged: 2:58:43 PM

Error fetching device events data: Failed to connect.`

What version of Home Assistant Core has the issue?

core-2024.6.3

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant OS

Integration causing the issue

overkiz

Link to integration documentation on our website

https://www.home-assistant.io/integrations/overkiz

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

home-assistant[bot] commented 3 months ago

Hey there @imicknl, @vlebourl, @tetienne, @nyrodev, @tronix117, mind taking a look at this issue as it has been labeled with an integration (overkiz) you are listed as a code owner for? Thanks!

Code owner commands Code owners of `overkiz` can trigger bot actions by commenting: - `@home-assistant close` Closes the issue. - `@home-assistant rename Awesome new title` Renames the issue. - `@home-assistant reopen` Reopen the issue. - `@home-assistant unassign overkiz` Removes the current integration label and assignees on the issue, add the integration domain after the command. - `@home-assistant add-label needs-more-information` Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue. - `@home-assistant remove-label needs-more-information` Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


overkiz documentation overkiz source (message by IssueLinks)

maumaumaumaumau commented 3 months ago

It looks like I have the same issue. My tahoma din rail box received an update today and since then connection via local API is impossible. Cloud API works, but is for me only a work around, because of known limitations.

edit: Connection via IP:8443 (no SSL) also doesn't work.

2024-06-21 23_48_03-Window 2024-06-21 23_48_31-Window

makhlouta commented 3 months ago

I deleted my hub on HA and added it again using the IP instead of gateway-xxx…. It has been stable for a while now

maumaumaumaumau commented 3 months ago

Have you used something like 192.168.178.30:8443 for the host and your usual (Somfy) online credentials? That didn't work for me.

makhlouta commented 3 months ago

Exactly what I did. Uncheck the SSL certificate option

rvdlinden commented 3 months ago

I have the same issue (and also the same box firmware). I was always stable on my fixed ip-address without SSL, but last week it began to drop-off on regular basis. Adding it again sometimes works, but in most cases it fails.

UPDATE: I just removed the hub based on gatewaylocal config from HA and added it back using the ip-address without SSL. Today is worked in one go without a problem. Yesterday this was not an option ;(

maumaumaumaumau commented 3 months ago

I had a network issue with, which happened on the same time as the somfy box received the update. Issue is resolved. Thank you for your support.

DjMoren commented 2 weeks ago

Today I tried to do it with HA 2024.9.1 version and had to do the ip + disable ssl combo to make it work