Hi all,
For some reason over the last few days I’ve been noticing some of my template sensors and dashboards are broken with unavailable values causing all kind of havoc errors, including of course automations.
Today I finally got some time to investigate the root cause, and it turns out its the REST platform that is sending bursts of the same request over and over again, a behavior that I did not see earlier, and its of course not welcome.
The portal I use has this REST API that limits the number of requests per minute, therefore I had set a scan_interval of 60 seconds to never have this kind of error.
I don’t know why, but it seems the scan_interval has suddenly become ignored, cause I already changed the config file to 3600 seconds, rebooted HASS, and still the errors keep coming back:
2024-07-31 09:41:16.361 DEBUG (MainThread) [homeassistant.components.rest.data] Data fetched from resource: {"exception":"Request calls within the current minute > threshold, please take note","code":104,"tokenId":"20xxxxxxxxxxxxxxxxxxxx0415","success":false}
2024-07-31 09:41:16.364 WARNING (MainThread) [homeassistant.components.rest.util] JSON result was not a dictionary or list with 0th element a dictionary
2024-07-31 09:41:16.406 DEBUG (MainThread) [homeassistant.components.rest.data] Data fetched from resource: {"exception":"Request calls within the current minute > threshold, please take note","code":104,"tokenId":"20xxxxxxxxxxxxxxxxxxxx0415","success":false}
2024-07-31 09:41:16.406 WARNING (MainThread) [homeassistant.components.rest.util] JSON result was not a dictionary or list with 0th element a dictionary
2024-07-31 09:41:16.409 DEBUG (MainThread) [homeassistant.components.rest.data] Data fetched from resource: {"exception":"Request calls within the current minute > threshold, please take note","code":104,"tokenId":"20xxxxxxxxxxxxxxxxxxxx0415","success":false}
2024-07-31 09:41:16.409 WARNING (MainThread) [homeassistant.components.rest.util] JSON result was not a dictionary or list with 0th element a dictionary
2024-07-31 09:41:16.413 DEBUG (MainThread) [homeassistant.components.rest.data] Data fetched from resource: {"exception":"Request calls within the current minute > threshold, please take note","code":104,"tokenId":"20xxxxxxxxxxxxxxxxxxxx0415","success":false}
2024-07-31 09:41:16.414 WARNING (MainThread) [homeassistant.components.rest.util] JSON result was not a dictionary or list with 0th element a dictionary
2024-07-31 09:41:16.416 DEBUG (MainThread) [homeassistant.components.rest.data] Data fetched from resource: {"exception":"Request calls within the current minute > threshold, please take note","code":104,"tokenId":"20xxxxxxxxxxxxxxxxxxxx0415","success":false}
2024-07-31 09:41:16.416 WARNING (MainThread) [homeassistant.components.rest.util] JSON result was not a dictionary or list with 0th element a dictionary
2024-07-31 10:41:16.273 DEBUG (MainThread) [homeassistant.components.rest.data] Data fetched from resource: {"exception":"Request calls within the current minute > threshold, please take note","code":104,"tokenId":"20xxxxxxxxxxxxxxxxxxxx0415","success":false}
2024-07-31 10:41:16.274 WARNING (MainThread) [homeassistant.components.rest.util] JSON result was not a dictionary or list with 0th element a dictionary
2024-07-31 10:41:16.356 DEBUG (MainThread) [homeassistant.components.rest.data] Data fetched from resource: {"exception":"Request calls within the current minute > threshold, please take note","code":104,"tokenId":"20xxxxxxxxxxxxxxxxxxxx0415","success":false}
2024-07-31 10:41:16.356 WARNING (MainThread) [homeassistant.components.rest.util] JSON result was not a dictionary or list with 0th element a dictionary
2024-07-31 10:41:16.395 DEBUG (MainThread) [homeassistant.components.rest.data] Data fetched from resource: {"exception":"Request calls within the current minute > threshold, please take note","code":104,"tokenId":"20xxxxxxxxxxxxxxxxxxxx0415","success":false}
2024-07-31 10:41:16.396 WARNING (MainThread) [homeassistant.components.rest.util] JSON result was not a dictionary or list with 0th element a dictionary
2024-07-31 10:41:16.428 DEBUG (MainThread) [homeassistant.components.rest.data] Data fetched from resource: {"exception":"Request calls within the current minute > threshold, please take note","code":104,"tokenId":"20xxxxxxxxxxxxxxxxxxxx0415","success":false}
2024-07-31 10:41:16.431 WARNING (MainThread) [homeassistant.components.rest.util] JSON result was not a dictionary or list with 0th element a dictionary
2024-07-31 10:41:16.454 DEBUG (MainThread) [homeassistant.components.rest.data] Data fetched from resource: {"exception":"Request calls within the current minute > threshold, please take note","code":104,"tokenId":"20xxxxxxxxxxxxxxxxxxxx0415","success":false}
2024-07-31 10:41:16.455 WARNING (MainThread) [homeassistant.components.rest.util] JSON result was not a dictionary or list with 0th element a dictionary
Does anyone have any clue of what changed?
Maybe I missed something in some recent release note?
I just want to make sure it’s not something on my side that needs to be corrected before opening an issue on git.
One thing is for sure true: I did not change anything in these rest sensors recently, they’ve been stable for years.
Thanks in advance for your valuable inputs.
Cheers,
-jprates