core: Retrying setup: Invalid response from API: Error occurred while communicating with device
The problem
I am no longer able to control any of my Roku’s via HA. They are all showing the same error under 'Integrations".
What version of Home Assistant Core has the issue?
Home Assistant 2023.3.6
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant Container
Integration causing the issue
Roku integration
Link to integration documentation on our website
https://www.home-assistant.io/integrations/roku
Diagnostics information
No response
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Logger: homeassistant.config_entries
Source: config_entries.py:1244
First occurred: 5:50:58 PM (1 occurrences)
Last logged: 5:50:58 PM
Config entry 'Roku Ultra' for roku integration not ready yet: Invalid response from API: Error occurred while communicating with device; Retrying in background
Additional information
No response
About this issue
- Original URL
- State: closed
- Created a year ago
- Reactions: 9
- Comments: 42 (2 by maintainers)
@meastman thanks for the insights, I was just looking at both roku and ipp for similiar issues again for code in setup that might explain the behavior and ran into the coordinator reuse and was tracking back the reason for such (memory leaks around garbage collection)
Home Assistant 2023.5.4 Supervisor 2023.04.1 Operating System 10.2
I have exactly the same issue with the IPP integration, which tells me this is a general HA issue and not specific to one integration. If the printer is switched off, and then back on again (but retains the same IP address as it’s static), I get this error message. Deleting and re-creating the integration solves the issue until the printer is switched off again. As the printer power is controlled by HA, it means HA shoots itself in the foot 👎
Log entries:
Just got it again… Retrying setup: Invalid response from API: Error occurred while communicating with device This is driving me (and especially the wife) nuts…
I think this is still a problem. I haven’t yet updated to 2023.5 (still on 2023.4). My Roku has always had a static IP assigned by my router which I’ve checked hasn’t changed. Although it does sometimes lose connection, this usually just throws an error not break the whole integration. Removing and re-adding fixes, but seems to only be temporary.
Same here.
In my case, the initial request to my Rokus will occasionally timeout during home assistant startup, probably just due to my Pi being briefly overloaded. Prior to 2023.5, the roku integration would consistently recover when this happened, but it looks like a combination of coordinator reuse (not a new change) and #91748 (first in 2023.5; leaves the coordinator in a bad state) leaves the integration in a bad state.
I was just mentioning that coordinator reuse may also be the cause of problems for people with Roku IPs that change.
I hear the feedback, I really feel this is partly from the HA upgrade side but there could be something else underlying but tracing it is going to be a task. Most our tests exclude HA internal testing and focus on a working test environment so the intermittent issues solved by reboot are tough to emulate. I’m currently trying to catch up with overall changes past few releases to see
This definitely seems intermittent to me. I’ve not updated to 2023.5 yet. After having these problems and removing and re-adding the integration several times at the start of the week, my Roku has now remained connected to HA for the last few days.
This is occurring on all 3 of my Roku devices… was definitely a recent HA update. Was working great prior.