danielperna84 / hahomematic

Python 3 Interface for Home Assistant to interact with HomeMatic devices
MIT License
136 stars 21 forks source link

hahomematic lists all devices as unavailable, although they are available in raspberryMatic #912

Closed ElGauchooooo closed 1 year ago

ElGauchooooo commented 1 year ago

DONT'T DELETE THIS.

This is for issues only If you have a feature request, add it as a new discussion, or add your point of view to an existing discussion.

Please answer all questions as good as possible.

Language: as you like -> english/DEUTSCH

Make sure you have read the documentation at https://github.com/danielperna84/custom_homematic#custom_homematic.

Make sure you have read the release notes at https://github.com/danielperna84/custom_homematic/releases.

Make sure you are running the latest version of the custom_component (and Home Assistant) before reporting an issue.

ENSURE that your Backend (CCU/Homegear/...) is working as expected and connected devices are controllable.

custom_component version (if applicable): 1.28.0

known last working custom_component version (if applicable): 1.x.x

Home Assistant:

CCU:

Problem-relevant configuration:

Do you use tls? no Do you use callback? no Do you use username and password? yes Which interfaces do you use (hmip/bidcos/wired)?

Describe the bug A clear and concise description of what the bug is.

I've recently updated to HA 2023.17.1 and afterwards to HAOS 2023.2.0. Today i realized that i could not control any of the homematic devices via HA and checked the logs. It repeatingly reports the following lines over and over again:

2023-02-02 15:54:42.900 WARNING (SyncWorker_3) [pyhomematic._hm] Failed to initialize proxy for homeassistant-wired
2023-02-02 15:54:43.348 WARNING (MainThread) [hahomematic.central_unit] CREATE_CLIENTS failed for RaspberryMatic
2023-02-02 15:54:43.356 WARNING (MainThread) [hahomematic.central_unit] CHECK_CONNECTION failed: No clients exist. Trying to create clients for server RaspberryMatic
2023-02-02 15:54:43.463 WARNING (MainThread) [hahomematic.central_unit] CREATE_CLIENTS failed for RaspberryMatic
2023-02-02 15:54:58.464 WARNING (MainThread) [hahomematic.central_unit] CHECK_CONNECTION failed: No clients exist. Trying to create clients for server RaspberryMatic
2023-02-02 15:54:58.467 WARNING (MainThread) [hahomematic.central_unit] CREATE_CLIENTS failed for RaspberryMatic
2023-02-02 15:55:13.469 WARNING (MainThread) [hahomematic.central_unit] CHECK_CONNECTION failed: No clients exist. Trying to create clients for server RaspberryMatic`

To Reproduce Steps to reproduce the behavior: see above

Screenshots (if applicable) image

Relevant HA log entries (press full log) VERY IMPORTANT

2023-02-02 15:54:42.900 WARNING (SyncWorker_3) [pyhomematic._hm] Failed to initialize proxy for homeassistant-wired
2023-02-02 15:54:43.348 WARNING (MainThread) [hahomematic.central_unit] CREATE_CLIENTS failed for RaspberryMatic
2023-02-02 15:54:43.356 WARNING (MainThread) [hahomematic.central_unit] CHECK_CONNECTION failed: No clients exist. Trying to create clients for server RaspberryMatic
2023-02-02 15:54:43.463 WARNING (MainThread) [hahomematic.central_unit] CREATE_CLIENTS failed for RaspberryMatic
2023-02-02 15:54:58.464 WARNING (MainThread) [hahomematic.central_unit] CHECK_CONNECTION failed: No clients exist. Trying to create clients for server RaspberryMatic
2023-02-02 15:54:58.467 WARNING (MainThread) [hahomematic.central_unit] CREATE_CLIENTS failed for RaspberryMatic
2023-02-02 15:55:13.469 WARNING (MainThread) [hahomematic.central_unit] CHECK_CONNECTION failed: No clients exist. Trying to create clients for server RaspberryMatic````

**Diagnostic Information (available on every device)**

{ "home_assistant": { "installation_type": "Home Assistant OS", "version": "2023.2.0", "dev": false, "hassio": true, "virtualenv": false, "python_version": "3.10.7", "docker": true, "arch": "x86_64", "timezone": "Europe/Berlin", "os_name": "Linux", "os_version": "5.15.90", "supervisor": "2023.01.1", "host_os": "Home Assistant OS 9.5", "docker_version": "20.10.22", "chassis": "vm", "run_as_root": true }, "custom_components": { "hacs": { "version": "1.25.5", "requirements": [ "aiogithubapi>=22.2.4" ] }, "homematicip_local": { "version": "1.28.0", "requirements": [ "hahomematic==2023.2.1" ] } }, "integration_manifest": { "domain": "homematicip_local", "name": "Homematic(IP) Local", "config_flow": true, "documentation": "https://github.com/danielperna84/custom_homematic", "issue_tracker": "https://github.com/danielperna84/hahomematic/issues", "requirements": [ "hahomematic==2023.2.1" ], "ssdp": [ { "manufacturer": "EQ3", "manufacturerURL": "http://www.homematic.com" } ], "zeroconf": [], "homekit": {}, "dependencies": [], "codeowners": [ "@danielperna84", "@SukramJ" ], "iot_class": "local_push", "loggers": [ "hahomematic" ], "version": "1.28.0", "integration_type": "hub", "is_built_in": false }, "data": { "config": { "entry_id": "432c6e1c9401fe6477444244a1bb1a32", "version": 1, "domain": "homematicip_local", "title": "RaspberryMatic", "data": { "instance_name": "RaspberryMatic", "host": "de838cd8-raspberrymatic", "username": "REDACTED", "password": "REDACTED", "tls": false, "verify_tls": false, "callback_host": null, "callback_port": null, "json_port": null, "interface": { "HmIP-RF": { "port": 2010 }, "BidCos-RF": { "port": 2001 } } }, "options": {}, "pref_disable_new_entities": false, "pref_disable_polling": false, "source": "user", "unique_id": "DA498FA9D3", "disabled_by": null }, "platform_stats": {}, "devices": [] } }

SukramJ commented 1 year ago

The integration is not able to connect to the Addon. Restart the RM Addon, wait 5 Minutes and restart HA.

Baxxy13 commented 1 year ago

Wenn ich das richtig sehe ist BidCos-RF aktiviert. Im geöffnetem Issue bei RaspberryMatic sieht man aber das ein HmIP-RFUSB-TK verwendet wird, welcher nicht BidCos fähig ist.

ElGauchooooo commented 1 year ago

@SukramJ danke für die Rückmeldung. Das Issue im RaspberryMatic Repo ist von mir, dort wurde mir geraten, es hier zu melden, wenn das RaspberryMatic AddOn die Geräte korrekt anzeigt - was es auch tut,

Das Posting im Community Forum ist nicht von mir, interpretiere ich aber so, dass es eventuell doch ein allgemeineres Issue ist und nicht ein lokaler / temporärer Bug. Neustarten des RM Addons und Restart von HA nach 5 Minuten habe ich versucht, bringt aber leider keine Abhilfe.

Dass der TK stick nicht mehr unterstützt wird, ist mir bewusst, schließe ich aber zumindest mal als Fehlerquelle zumindest in diesem Issue aus, da die Geräte problemlos im AddOn funktionieren.

Wenn ich weitere Infos zu dem Problem beitragen kann - gerne Rückmeldung an mich.

SukramJ commented 1 year ago

[pyhomematic._hm] Failed to initialize proxy for homeassistant-wired

  1. Deaktiviere/Lösch bitte die alte HM-Integration, denn die hat auch Verbindungsprobleme.
  2. HA neustarten. Ich hätte dann gerne das vollständige Log, und nicht nur einen Auszug.

Danach:

  1. DEBUG für die Integration aktivieren. Das geht über die rechte Maustaste auf der Integration. Erneute Versuche sollten jetzt im DEBUG protokolliert werden. Ich hätte dann gerne wieder das vollständige Log, und nicht nur einen Auszug.

Danach:

  1. Im DEBUG HA neustarten (ich hoffe DEBUG bleibt aktiviert) Ich hätte dann gerne wieder das vollständige Log, und nicht nur einen Auszug.

Mach erst mal 1+2 danach schauen wir weiter.

ElGauchooooo commented 1 year ago
  1. ist gelöscht.
  2. Log sah genau gleich aus.
  3. Mit den DebugLogs sieht man schon etwas mehr:
2023-02-02 19:40:40.592 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration homematicip_local which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2023-02-02 19:40:47.383 DEBUG (MainThread) [hahomematic.xml_rpc_server] Creating XmlRpc server
2023-02-02 19:40:47.384 DEBUG (XmlRpcServer on port 51155) [hahomematic.xml_rpc_server] RUN: Starting XmlRPC-Server at http://0.0.0.0:51155
2023-02-02 19:40:47.384 DEBUG (MainThread) [hahomematic.xml_rpc_server] REGISTER_XML_RPC_SERVER: Starting XmlRPC-Server
2023-02-02 19:40:47.467 DEBUG (SyncWorker_9) [hahomematic.parameter_visibility] LOAD: No file found in /config/homematicip_local
2023-02-02 19:40:47.491 DEBUG (SyncWorker_6) [hahomematic.central_unit] Got local ip: 172.30.32.1
2023-02-02 19:40:47.503 DEBUG (MainThread) [hahomematic.xml_rpc_proxy] __ASYNC_REQUEST: ('system.listMethods', ())
2023-02-02 19:40:47.533 DEBUG (MainThread) [hahomematic.xml_rpc_proxy] __ASYNC_REQUEST: ('getVersion', ())
2023-02-02 19:40:47.539 DEBUG (MainThread) [hahomematic.xml_rpc_proxy] __ASYNC_REQUEST: ('ping', ('RaspberryMatic-HmIP-RF',))
2023-02-02 19:40:47.569 DEBUG (MainThread) [hahomematic.json_rpc_client] GET_SERIAL: Getting the backend serial via JSON-RPC
2023-02-02 19:40:48.178 DEBUG (MainThread) [hahomematic.json_rpc_client] DO_LOGIN: Method: Session.login [qwvKJIuAsu]
2023-02-02 19:40:48.233 DEBUG (MainThread) [hahomematic.json_rpc_client] POST_SCRIPT: Method: ReGa.runScript [get_serial.fn]
2023-02-02 19:40:48.233 DEBUG (MainThread) [hahomematic.json_rpc_client] GET_AVAILABLE_INTERFACES: Getting all available interfaces via JSON-RPC
2023-02-02 19:40:48.233 DEBUG (MainThread) [hahomematic.json_rpc_client] POST: Method: Interface.listInterfaces, [None]
2023-02-02 19:40:48.303 DEBUG (MainThread) [hahomematic.central_unit] CREATE_CLIENTS: Adding client RaspberryMatic-HmIP-RF to RaspberryMatic
2023-02-02 19:40:48.303 DEBUG (MainThread) [hahomematic.xml_rpc_proxy] __ASYNC_REQUEST: ('system.listMethods', ())
2023-02-02 19:40:48.310 DEBUG (MainThread) [hahomematic.central_unit] CREATE_CLIENTS failed: Unable to create client for central [(<ProtocolError for de838cd8-raspberrymatic:2001/RPC2: 503 Service Unavailable>,)]
2023-02-02 19:40:48.310 WARNING (MainThread) [hahomematic.central_unit] CREATE_CLIENTS failed for RaspberryMatic
2023-02-02 19:40:48.313 DEBUG (MainThread) [hahomematic.central_unit] START_CONNECTION_CHECKER: Starting connection_checker for RaspberryMatic
2023-02-02 19:40:48.313 DEBUG (ConnectionChecker for RaspberryMatic) [hahomematic.central_unit] run: Init connection checker to server RaspberryMatic
2023-02-02 19:40:48.559 DEBUG (MainThread) [hahomematic.central_unit] check_connection: Checking connection to server RaspberryMatic
2023-02-02 19:40:48.559 WARNING (MainThread) [hahomematic.central_unit] CHECK_CONNECTION failed: No clients exist. Trying to create clients for server RaspberryMatic
2023-02-02 19:40:48.560 DEBUG (MainThread) [hahomematic.client] PROXY_DE_INIT: init('http://172.30.32.1:51155')
2023-02-02 19:40:48.560 DEBUG (MainThread) [hahomematic.xml_rpc_proxy] __ASYNC_REQUEST: ('init', ('http://172.30.32.1:51155',))
2023-02-02 19:40:48.572 DEBUG (MainThread) [hahomematic.central_unit] STOP: Proxy de-initialized: RaspberryMatic-HmIP-RF
2023-02-02 19:40:48.572 DEBUG (MainThread) [hahomematic.central_unit] STOP_CLIENTS: Stopping RaspberryMatic-HmIP-RF
2023-02-02 19:40:48.572 DEBUG (MainThread) [hahomematic.central_unit] STOP_CLIENTS: Clearing existing clients.
2023-02-02 19:40:48.575 DEBUG (SyncWorker_5) [hahomematic.central_unit] Got local ip: 172.30.32.1
2023-02-02 19:40:48.641 DEBUG (MainThread) [hahomematic.xml_rpc_proxy] __ASYNC_REQUEST: ('system.listMethods', ())
2023-02-02 19:40:48.657 DEBUG (MainThread) [hahomematic.xml_rpc_proxy] __ASYNC_REQUEST: ('getVersion', ())
2023-02-02 19:40:48.662 DEBUG (MainThread) [hahomematic.xml_rpc_proxy] __ASYNC_REQUEST: ('ping', ('RaspberryMatic-HmIP-RF',))
2023-02-02 19:40:48.683 DEBUG (MainThread) [hahomematic.json_rpc_client] GET_SERIAL: Getting the backend serial via JSON-RPC

Interpretiere ich das richtig, dass hier irgendein Service, der für die Kommunikation zwischen AddOn und hahomematic zuständig ist, nicht verfügbar ist? Eventuell doch ein Problem aus dem AddOn? <ProtocolError for de838cd8-raspberrymatic:2001/RPC2: 503 Service Unavailable>

Edit: Auch ein paar Minuten später passiert genau das gleiche immer und immer wieder, nichts neues in den Logs.

SukramJ commented 1 year ago

<ProtocolError for de838cd8-raspberrymatic:2001/RPC2: 503 Service Unavailable>

Hierauf hat schon @Baxxy13 Bezug genommen. Dein HmIP-RFUSB-TK kann kein BidCos. Also solltest du auch die Verwendung von Bicos-RF/ Port 2001 aus der Konfiguration der Integration entfernen.

Danach bitte noch mal neue Logs einstellen.

ElGauchooooo commented 1 year ago

Das scheint es schon gewesen zu sein - sorry, hatte das falsch interpretiert. Interessant, da ich vor dem HA-Update nichts geändert hatte. Nach Entfernen von Bidcos-RF aus der Config der Integration tauchen alle Geräte sofort wieder auf.

image