anotherjulien / MyHOME

MyHOME integration for Home-Assistant
GNU Affero General Public License v3.0
137 stars 57 forks source link

Error setting up entry MH200N Gateway for myhome #86

Open 4tViert opened 1 year ago

4tViert commented 1 year ago

Hello, pretty new here so I hope someone can help. I have installed this repository almost 2 years ago without any problems, but since last week I cannot connect to my gateway anymore. Before I had all coding in the config.yaml and after checking I have reated a new file according to wiki named myhome.yaml and changed the syntax. But I cannot connect. There are 2 errors:

Error doing job: Tas exception was never retrieved and Error setting up entry MH200N Gateway for myhome

No idea how to solve. Do i need to set a reference in config.yaml or any other things to adapt? grafik

Thx.

Brg

caiosweet commented 1 year ago

Have you tried uninstalling the component, restarting and installing again. It may happen that outdated configurations remain. Did you set the gateway in the configuration with the mac address? For example as per wiki general-structure:


mh202n:
   mac: "00:00:50:11:B8:55"

   binary_sensor:
     pir_xxx:
       where: "331"
       name: Pir xxx
       class: motion
       manufacturer: BTicino
       model: N4640
     pir_yyy:
       where: "371"
       name: Pir yyy
       class: motion
       manufacturer: BTicino
       model: NT4610

   covers:
     cover_studio:
     ...
4tViert commented 1 year ago

Thanks for your message. I have already tried all these above mentioned things but this is the error message that appears.

Logger: homeassistant.config_entries Source: loader.py:1045 First occurred: 08:50:00 (1 occurrences) Last logged: 08:50:00

Error setting up entry MH200N Gateway for myhome Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/config_entries.py", line 387, in async_setup result = await component.async_setup_entry(hass, self) File "/config/custom_components/myhome/init.py", line 89, in async_setup_entry device_registry = await hass.helpers.device_registry.async_get_registry() File "/usr/src/homeassistant/homeassistant/loader.py", line 1045, in getattr value = getattr(self._module, attr) AttributeError: module 'homeassistant.helpers.device_registry' has no attribute 'async_get_registry'

caiosweet commented 1 year ago

Uuuhmm... I'm unable to help you, but it seems that the error refers to async_get_registry which has been re-set in recent versions of myhome. It's like in home assistant, it didn't get the new version.

Have you tried installing the new version directly from the Master?

anotherjulien commented 1 year ago

I think that indeed the version used is outdated. The line that is causing the error has been absent from the code base since June 5th 2022.

4tViert commented 1 year ago

Thanks for all the input. Finally I solved the problem. Every time i deleted the myhome intregration from my hass.io I made a restart of the complete system and installed it again, without success. Now I have deleted the integration restarted - deleted from HACS as well - restartet - then I used the link from github again - installed in HACS - restartet - thenn startet integration in HassIO and it WORKS!!!! Once again many thanks, 2 weeks without a running home assistant and the functions is horrible.