Integration configuration fails with 'Retrying setup: 0'
MrDeon opened this issue · 1 comments
MrDeon commented
Have tried a few times to move from the official Envoy integration to this one, and each time the integration fails to complete setup. The integration status shows as Retrying Setup: 0
Logs show:
Unexpected error fetching envoy Envoy 122121001072 data: 0
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 187, in _async_refresh
self.data = await self._async_update_data()
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 147, in _async_update_data
return await self.update_method()
File "/config/custom_components/enphase_envoy/__init__.py", line 63, in async_update_data
battery_data = await envoy_reader.battery_storage()
File "/config/custom_components/enphase_envoy/envoy_reader.py", line 721, in battery_storage
if len(ensemble_json) > 0 and "devices" in ensemble_json[0].keys():
KeyError: 0
briancmpbll commented
That looks like an array index error, but the length check should guard against it. I'm not super familiar with python though. You should add an issue to https://github.com/DanBeard/envoy_reader, since this is his code.