Apparently, version 0.61 introduced a lot of changes related to ISY994i. Since the update, every 10 minutes or so, I get the following in my logs:
Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/lib/python3.6/asyncio/tasks.py", line 180, in _step
result = coro.send(None)
File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 218, in async_update_ha_state
device_attr = self.device_state_attributes
File "/usr/lib/python3.6/site-packages/homeassistant/components/isy994.py", line 472, in device_state_attributes
for name, val in self._node.aux_properties.items():
AttributeError: 'list' object has no attribute 'items'
Does anyone have any idea what could be wrong or point me in the right direction? Should I do anything about it. Everything seems to work.
Thanks!
EDIT: my issue persists up to the latest version (currently 0.64.3).
Can you go into your dev-state page in HA and search for āaux_propertiesā. It seems the code expects, that if found, that should be a dictionary, but in your instance, it is a list.
I also have an ISY but Iām on the old 4.x series firmware and I donāt have anything with āaux_propertiesā.
Sorry, I guess aux_props is actually a PyISY thing. In PyISY, aux_props is a list of dictionary. I think inside isy994.py itāll need to be changed to iterate the list of dictionary.
You might be able to copy the isy994.py file over to custom_components and change
for name, val in self._node.aux_properties.items():
attr[name] = '{} {}'.format(val.get('value'), val.get('uom'))
to
for prop in self._node.aux_properties:
attr[prop.get('id')] = '{} {}'.format(prop.get('value'), prop.get('uom'))
This is just speculation based on what I see in github. Not tested.
Figured Iād chime in, Iām also getting the same error in the logs:
2018-01-19 18:58:42 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/lib/python3.5/asyncio/tasks.py", line 239, in _step
result = coro.send(None)
File "/usr/local/lib/python3.5/dist-packages/homeassistant/helpers/entity_component.py", line 399, in async_process_entity
new_entity, self, update_before_add=update_before_add
File "/usr/local/lib/python3.5/dist-packages/homeassistant/helpers/entity_component.py", line 247, in async_add_entity
yield from entity.async_update_ha_state()
File "/usr/local/lib/python3.5/dist-packages/homeassistant/helpers/entity.py", line 218, in async_update_ha_state
device_attr = self.device_state_attributes
File "/usr/local/lib/python3.5/dist-packages/homeassistant/components/isy994.py", line 472, in device_state_attributes
for name, val in self._node.aux_properties.items():
AttributeError: 'list' object has no attribute 'items'
I would, but I donāt have anything with aux_properties, so I canāt really test if my suggestion would work. Iām pretty sure it would, but it would also be nice to know.
I am not familiar with Hass.io. Do you have the ability to modify a component? We would need to make a copy of the isy994.py file and then make some changes to the original.
You would need to create a custom_components folder inside your config directory, and then we would put a modified copy of isy994.py there. Does that seem like something you want to try?
Yes, I could do that. Thatās a great idea. A custom component would override the existing one. Can you post the original one and the modification required? I will testā¦
Here is what I did: I copied the isy994.py file from:
to my local ācustom_componentsā directory. I edited the file as suggested above (line 472 and 473 of isy994.py), then restarted HA. I think thatās the only thing I need to do. That new file should automatically be used instead of the āoldā built-in one.
The results are exactly the same. Nothing got broken from what I can see, but I get the same error message in my logs:
Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/lib/python3.6/asyncio/tasks.py", line 180, in _step
result = coro.send(None)
File "/usr/lib/python3.6/site-packages/homeassistant/helpers/entity.py", line 223, in async_update_ha_state
device_attr = self.device_state_attributes
File "/usr/lib/python3.6/site-packages/homeassistant/components/isy994.py", line 472, in device_state_attributes
for name, val in self._node.aux_properties.items():
AttributeError: 'list' object has no attribute 'items'