timmo001 / homeassistant-integration-goxlr-utility

Home Assistant Integration - GoXLR Utility
https://timmo.dev
MIT License
3 stars 2 forks source link

Some lighting entities not working #18

Open Dreamtrailtv opened 1 year ago

Dreamtrailtv commented 1 year ago

Description

Direkt nach der initialisierung wurden paar licht entitäten nicht richtig konfiguriert

Anything in the logs or a references that might be useful?

Logger: homeassistant
Source: custom_components/goxlr_utility/light.py:53
Integration: GoXLR Utility (documentation, issues)
First occurred: 01:10:51 (168 occurrences)
Last logged: 01:24:58

Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/config/custom_components/goxlr_utility/coordinator.py", line 150, in _patch_callback_task
    self.async_set_updated_data(new_data)
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 371, in async_set_updated_data
    self.async_update_listeners()
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 142, in async_update_listeners
    update_callback()
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 401, in _handle_coordinator_update
    self.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 568, in async_write_ha_state
    self._async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 632, in _async_write_ha_state
    state = self._stringify_state(available)
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 574, in _stringify_state
    if (state := self.state) is None:
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1016, in state
    if (is_on := self.is_on) is None:
  File "/config/custom_components/goxlr_utility/light.py", line 133, in is_on
    return self.rgb_color != (0, 0, 0)
  File "/config/custom_components/goxlr_utility/light.py", line 138, in rgb_color
    hex_value = self.entity_description.hex(
  File "/config/custom_components/goxlr_utility/light.py", line 53, in <lambda>
    ).colours.colour_one,
AttributeError: 'dict' object has no attribute 'colours'

Additional information

No response

timmo001 commented 1 year ago

Are you using a full GoXLR, or a GoXLR mini?

The line the error is on, is a button, specifically the active one:

https://github.com/timmo001/homeassistant-integration-goxlr-utility/blob/99b2e59b6c14c4023859cc3d6e4794d1a3eb028d/custom_components/goxlr_utility/light.py#L41-L53

Can you post a screenshot of which entities are showing as unknown/errored?

Dreamtrailtv commented 1 year ago

It's a full GoXLR and GoXLR Utility is on the latest version.

image

timmo001 commented 1 year ago

Does is the latest version (1.2.2) help with these errors?

I may need an extract of the JSON so may require you to enable debug log levels on custom_components.goxlr_utility and goxlrutilityapi so I can update the models to suit the full GoXLR

Dreamtrailtv commented 1 year ago

Does is the latest version (1.2.2) help with these errors?

I may need an extract of the JSON so may require you to enable debug log levels on custom_components.goxlr_utility and goxlrutilityapi so I can update the models to suit the full GoXLR

I don't know right now where I extract this data.