cgtobi / netatmo_custom

This repo is a custom component from the beta version of the official HA netatmo component
MIT License
13 stars 6 forks source link

Errors during startup #11

Closed confucius78 closed 2 years ago

confucius78 commented 2 years ago

I see a couple of errors when starting up the HA instance. In terms of hardware, I have a doorbell, weather station indoor&outdoor, wind meter and rain meter. All the weather stuff seems to work fine and I am not missing anything unless the expected behavior is to have a switch and/or sensor for the doorbell.

HA version was updated just now to HA2022-03-04


Logger: homeassistant.components.switch
Source: custom_components/netatmo/switch.py:40
Integration: Switch ([documentation](https://www.home-assistant.io/integrations/switch), [issues](https://github.com/home-assistant/home-assistant/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+switch%22))
First occurred: 3:05:03 PM (1 occurrences)
Last logged: 3:05:03 PM
Error while setting up netatmo platform for switch

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 249, in _async_setup_platform
    await asyncio.shield(task)
  File "/config/custom_components/netatmo/switch.py", line 40, in async_setup_entry
    if not account_topology or account_topology.raw_data == {}:
AttributeError: 'AsyncAccount' object has no attribute 'raw_data'

Logger: homeassistant.components.sensor
Source: custom_components/netatmo/sensor.py:283
Integration: Sensor ([documentation](https://www.home-assistant.io/integrations/sensor), [issues](https://github.com/home-assistant/home-assistant/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+sensor%22))
First occurred: 3:05:56 PM (1 occurrences)
Last logged: 3:05:56 PM
Error while setting up netatmo platform for sensor

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 249, in _async_setup_platform
    await asyncio.shield(task)
  File "/config/custom_components/netatmo/sensor.py", line 283, in async_setup_entry
    if not account_topology or account_topology.raw_data == {}:
AttributeError: 'AsyncAccount' object has no attribute 'raw_data'
confucius78 commented 2 years ago

FYI: I did some side-by-side checking, and it seems this is due to startup being a bit slow and the platform not yet being ready, correct?

cgtobi commented 2 years ago

I pushed an update to clean up this error.