Multiple Entity calculation timeout
matmal opened this issue · comments
matmal commented
Environment
- Home Assistant Core release with the issue:2022.10.4
- This custom component release with the issue: 2.3.0
- Last working this custom component release (if known):
- Operating environment (Home Assistant/Supervisor/Docker/venv): Docker
Describe the bug
If an average of 1+ entities (like temperature) is performed. Home assistant reports an error that calculation takes mor than 10 seconds. This puts a lot of stress on the cpu thus HA becomes unresponsive.
Configuration.yaml
- platform: average
name: "1D Avg Temp"
duration:
days: 1
entities:- sensor.temperatura_1
- sensor.temperatura_2
- sensor.temperatura_3
- sensor.temperatura_4
Steps to Reproduce
Use any changing values to reproduce this, does not have to be temperature
Expected behavior
Debug log
Additional context
2022-10-19 11:46:20.006 WARNING (MainThread) [homeassistant.helpers.entity] Update of sensor.1d_avg_temp is taking over 10 seconds