sensor.unifigateway icon indicating copy to clipboard operation
sensor.unifigateway copied to clipboard

Problem since version 2024.2.2

Open bucley opened this issue 1 year ago • 5 comments

I can no longer get any information since the version of home assistant in 2024.2.2. Am I the only one or are other people in the same situation?

THANKS

bucley avatar Feb 18 '24 16:02 bucley

Logger: homeassistant.helpers.template Source: helpers/template.py:2345 First occurred: 17:06:23 (16 occurrences) Last logged: 17:06:23

Template variable error: 'None' has no attribute 'attributes' when rendering '{{ states.sensor.unifi_status_www.attributes.xput_up }}' Template variable error: 'None' has no attribute 'attributes' when rendering '{{ states.sensor.unifi_status_www.attributes.speedtest_ping }}' Template variable error: 'None' has no attribute 'attributes' when rendering '{%- set time = states.sensor.unifi_status_www.attributes.uptime | int %} {%- set minutes = ((time % 3600) // 60) %} {%- set minutes = '{}min'.format(minutes) if minutes > 0 else '' %} {%- set hours = ((time % 86400) // 3600) %} {%- set hours = '{}hr '.format(hours) if hours > 0 else '' %} {%- set days = (time // 86400) %} {%- set days = '{}d '.format(days) if days > 0 else '' %} {{ 'Less than 1 min' if time < 60 else days + hours + minutes }}' Template variable error: 'None' has no attribute 'attributes' when rendering '{{ states.sensor.unifi_status_wlan.attributes.num_user }}' Template variable error: 'None' has no attribute 'attributes' when rendering '{{ states.sensor.unifi_status_lan.attributes.num_user }}'

bucley avatar Feb 18 '24 16:02 bucley

I am getting the following in main HA logs...

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 942, in async_update_ha_state
    await self.async_device_update()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1261, in async_device_update
    await hass.async_add_executor_job(self.update)
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/util/__init__.py", line 190, in wrapper
    result = method(*args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/unifigateway/sensor.py", line 174, in update
    if sub['subsystem'] == self._sensor:
       ~~~^^^^^^^^^^^^^
TypeError: string indices must be integers, not 'str'

geftactics avatar Feb 19 '24 11:02 geftactics

I have the same issue

sthevenp avatar Feb 24 '24 20:02 sthevenp

Same for me to

plouf34 avatar Feb 25 '24 19:02 plouf34

same issue at me

Liionboy avatar Mar 08 '24 21:03 Liionboy