You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Logger: homeassistant
Source: util/color.py:633
First occurred: 12:46:33 (131 occurrences)
Last logged: 19:19:18
Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/local/lib/python3.12/site-packages/aiohue/v2/controllers/base.py", line 247, in _handle_event
callback(evt_type, cur_item)
File "/usr/src/homeassistant/homeassistant/components/hue/v2/entity.py", line 138, in _handle_event
self.async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 998, in async_write_ha_state
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1119, in _async_write_ha_state
state, attr, capabilities, shadowed_attr = self.__async_calculate_state()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1051, in __async_calculate_state
capability_attr = self.capability_attributes
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 1027, in capability_attributes
max_color_temp_kelvin = self.max_color_temp_kelvin
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/light/__init__.py", line 1005, in max_color_temp_kelvin
return color_util.color_temperature_mired_to_kelvin(self.min_mireds)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/util/color.py", line 633, in color_temperature_mired_to_kelvin
return math.floor(1000000 / mired_temperature)
~~~~~~~~^~~~~~~~~~~~~~~~~~~
ZeroDivisionError: division by zero
Additional information
The light was unresponsive for new commands. The electronics got into some error state. After power cycling the light, these where the properties, with a responsive light:
Hey there @balloob, @marcelveldt, mind taking a look at this issue as it has been labeled with an integration (hue) you are listed as a code owner for? Thanks!
Code owner commands
Code owners of hue can trigger bot actions by commenting:
@home-assistant close Closes the issue.
@home-assistant rename Awesome new title Renames the issue.
@home-assistant reopen Reopen the issue.
@home-assistant unassign hue Removes the current integration label and assignees on the issue, add the integration domain after the command.
@home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
@home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.
The event was a one-off. Didn't happen again. But guarding the code,at the spot where the exceptions came from, against divisions by zero is always a good idea
The problem
Since my update to core 2024.4.4 I see division by zero errors. My HUE setup has not changed over the last months.
What version of Home Assistant Core has the issue?
Core-2024.4.4
What was the last working version of Home Assistant Core?
Core-2024.4.3
What type of installation are you running?
Home Assistant OS
Integration causing the issue
Hue
Link to integration documentation on our website
https://www.home-assistant.io/integrations/hue/
Diagnostics information
According my logbook, errors started after an innr PL 110 led was switched on:
That is a dimmable light only. No colors, no color temperature. Properties of this light in dev tools:
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Additional information
The light was unresponsive for new commands. The electronics got into some error state. After power cycling the light, these where the properties, with a responsive light:
The text was updated successfully, but these errors were encountered: