home-connect-hass: API call for active program 404 results in excessive number of API calls
Keep getting BLOCKED due to excessive number of API calls
I think this is due to the call for the active program for a coffee machine getting 404 and the component constantly retrying. See attached debug log.
Version of the custom_component
0.6.3
Debug log
2023-06-25 21:06:03.329 DEBUG (MainThread) [home_connect_async.api] HTTP GET /api/homeappliances/SIEMENS-CT836LEB6-ABCDEFGHIJKL/programs/active (try=1 count=663) [404]
2023-06-25 21:06:03.330 DEBUG (MainThread) [home_connect_async.api] API call failed with code=404 error=SDK.Error.NoProgramActive
2023-06-25 21:06:03.330 DEBUG (MainThread) [home_connect_async.appliance] Failed to load active programs with error code=404 key=SDK.Error.NoProgramActive
2023-06-25 21:06:03.331 DEBUG (MainThread) [home_connect_async.api]
HTTP GET /api/homeappliances/SIEMENS-CT836LEB6-ABCDEFGHIJKL/programs/available (try=1 count=664)
About this issue
- Original URL
- State: closed
- Created a year ago
- Reactions: 2
- Comments: 28 (22 by maintainers)
@pbvdven I’m afraid that’s not going to be possible.
@pbvdven well, he didn’t reach out and I’m not sure he understands how Home Assistant works. Keeping the sensors and options up-to-date requires API calls when certain statuses change. However, if he has any constructive suggestions how to avoid that I’m happy to learn.
Thanks. I’ll take a look at it but it will have to wait until I return from my vacation towards the end of August.
You can upload a full debug log for at least 48h
Here you go - most of the “surplus” calls are for child lock (448 times), sabbath mode (16 times, but basically every time the oven is used), PowerState (637 times), TemperatureUnit (56) Appreciate it’s difficult getting the current state of the appliances - that’s why I was wondering whether there was any way of caching/throttling some calls for the “basic” settings such as child lock.
2023-07-08 HOME_CONNECT.LOG
Thanks for responding so quickly - have deleted and re-added the machine but still get the 404 error and a lot of API calls.
Back story is I have an automation which turns the machine on, waits for ready state then changes the selected program to espresso using the select program service (but does not actually run the program)
I think the problem is when the machine is turned on, the “active program” is cleaning which when you query the API for details it says no program active as the cleaning function has finished but no program is active (as the machine isn’t brewing coffee).
"uri":"/api/homeappliances/SIEMENS-CT836LEB6-ABCDEFGHIJKL/programs/active","value":"ConsumerProducts.CoffeeMaker.Program.CleaningModes.ApplianceOnRinsing"}]}. and then when the machine is properly turned on, the component queries the machine again for the active programLater on when the program selection changes, the component again queries for the active program
on another note, there does seem to be a lot of calls for available programs : any chance you could cache the data?
debug log attached… 2023-06-27.log
I have a similar problem with this add on and a dishwasher. I get blocked almost every day 😐