bramstroker / homeassistant-powercalc

Custom component to calculate estimated power consumption of lights and other appliances
MIT License
973 stars 258 forks source link

Error during setup of component powercalc #1069

Closed Marmoulak closed 2 years ago

Marmoulak commented 2 years ago

Hi I get this error. I have latest release of powercalc. Home Assistant 2022.9.1 Supervisor 2022.08.6 Operating System 8.5 Frontend 20220907.0 - latest

I have disabled all devices under powercalc in configuration.yaml but did not help. Can you please help? Regard

Logger: homeassistant.setup Source: custom_components/powercalc/init.py:267 Integration: powercalc (documentation, issues) First occurred: 12:35:36 AM (1 occurrences) Last logged: 12:35:36 AM Error during setup of component powercalc 2022-09-10 00:35:36.330 DEBUG (MainThread) [custom_components.powercalc] light.ak001_zj2101_d8f15ba24348: Model not found in library, skipping auto configuration 2022-09-10 00:35:36.331 DEBUG (MainThread) [custom_components.powercalc.power_profile.model_discovery] light.ak001_zj2101_d8f15ba29956: Auto discovered model (manufacturer=Zengge, model=0x21) 2022-09-10 00:35:36.331 DEBUG (MainThread) [custom_components.powercalc] light.ak001_zj2101_d8f15ba29956: Model not found in library, skipping auto configuration 2022-09-10 00:35:36.331 DEBUG (MainThread) [custom_components.powercalc.power_profile.model_discovery] switch.ak001_zj2101_d8f15ba24348_remote_access: Auto discovered model (manufacturer=Zengge, model=0x21) 2022-09-10 00:35:36.331 DEBUG (MainThread) [custom_components.powercalc] switch.ak001_zj2101_d8f15ba24348_remote_access: Model not found in library, skipping auto configuration 2022-09-10 00:35:36.331 DEBUG (MainThread) [custom_components.powercalc.power_profile.model_discovery] switch.ak001_zj2101_d8f15ba29956_remote_access: Auto discovered model (manufacturer=Zengge, model=0x21) 2022-09-10 00:35:36.331 DEBUG (MainThread) [custom_components.powercalc] switch.ak001_zj2101_d8f15ba29956_remote_access: Model not found in library, skipping auto configuration 2022-09-10 00:35:36.332 DEBUG (MainThread) [custom_components.powercalc.power_profile.model_discovery] light.sonoff_10010aace5: Auto discovered model (manufacturer=SONOFF, model=B02-B) 2022-09-10 00:35:36.332 DEBUG (MainThread) [custom_components.powercalc] light.sonoff_10010aace5: Model not found in library, skipping auto configuration 2022-09-10 00:35:36.332 DEBUG (MainThread) [custom_components.powercalc.power_profile.model_discovery] switch.myhome_bluetooth_inquiries: Auto discovered model (manufacturer=, model=Docker Container) 2022-09-10 00:35:36.332 ERROR (MainThread) [homeassistant.setup] Error during setup of component powercalc Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/setup.py", line 235, in _async_setup_component result = await task File "/config/custom_components/powercalc/init.py", line 188, in async_setup await autodiscover_entities(config, domain_config, hass) File "/config/custom_components/powercalc/init.py", line 267, in autodiscover_entities if power_profile.is_additional_configuration_required: AttributeError: 'NoneType' object has no attribute 'is_additional_configuration_required'

Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/setup.py", line 235, in _async_setup_component result = await task File "/config/custom_components/powercalc/init.py", line 188, in async_setup await autodiscover_entities(config, domain_config, hass) File "/config/custom_components/powercalc/init.py", line 267, in autodiscover_entities if power_profile.is_additional_configuration_required: AttributeError: 'NoneType' object has no attribute 'is_additional_configuration_required'

JonasPed commented 2 years ago

I have seen the same issue with the latest release. It seems to be fixed in master branch. Can you try out the master branch?

Marmoulak commented 2 years ago

Thanks @JonasPed . It helped. Now is working again.

bramstroker commented 2 years ago

Just release v0.25.5 which also contains this fix.