Onkyo integration media_player entity drops out randomly

I have a Pioneer AVR that I control using the Onkyo integration. When the entity is detected it works flawlessly, but it’ll randomly drop out until I restart HA and even then sometimes it doesn’t pick back up.

Here’s an error I get in the log. Seems to happen regardless of if it’s detected or not. Some of my eiscp commands return error code 1 as well on occasion.

Logger: homeassistant.components.media_player
Source: helpers/entity_platform.py:356
integration: Media player (documentation, issues)
First occurred: 10:57:45 AM (1 occurrences)
Last logged: 10:57:45 AM

Error while setting up onkyo platform for media_player
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 356, in _async_setup_platform
    await asyncio.shield(awaitable)
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/config/custom_components/onkyo/media_player.py", line 226, in setup_platform
    zones = determine_zones(receiver)
  File "/config/custom_components/onkyo/media_player.py", line 160, in determine_zones
    response = receiver.raw("ZPWQSTN")
  File "/usr/local/lib/python3.12/site-packages/eiscp/core.py", line 470, in raw
    return filter_for_message(self.get, iscp_message)
  File "/usr/local/lib/python3.12/site-packages/eiscp/core.py", line 260, in filter_for_message
    candidate = getter_func(0.05)
  File "/usr/local/lib/python3.12/site-packages/eiscp/core.py", line 440, in get
    header = eISCPPacket.parse_header(header_bytes)
  File "/usr/local/lib/python3.12/site-packages/eiscp/core.py", line 101, in parse_header
    assert len(bytes) == 16