NVidia shield, integrated with Android Debug Bridge, is suddenly not working?

I know there was an issue for everyone with the shield over a year ago, I dont remember the details but it was solved by hardwiring the media box. Mine is hardwired.

Ive restarted both pieces, cleared all ADB connections to it, Ive seen the popup that asks if I want to give HA ADB permision and granted it, but still the integration is broken. “Failed to setup, check the logs”

The Logs:

2023-05-22 04:32:29.693 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration androidtv which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2023-05-22 04:32:46.596 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry 10.0.50.251 for androidtv
File "/config/custom_components/androidtv/__init__.py", line 162, in async_setup_entry
2023-05-22 08:34:06.401 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry 10.0.50.251 for androidtv
File "/config/custom_components/androidtv/__init__.py", line 162, in async_setup_entry

And here is the snippit of code that the log calls out, line 150-174:

    entry.async_on_unload(
        hass.bus.async_listen_once(EVENT_HOMEASSISTANT_STOP, async_close_connection)
    )
    entry.async_on_unload(entry.add_update_listener(update_listener))

    hass.data.setdefault(DOMAIN, {})[entry.entry_id] = {
        ANDROID_DEV: aftv,
        ANDROID_DEV_OPT: entry.options.copy(),
    }

    hass.config_entries.async_setup_platforms(entry, PLATFORMS)

    return True


async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
    """Unload a config entry."""
    if unload_ok := await hass.config_entries.async_unload_platforms(entry, PLATFORMS):
        aftv = hass.data[DOMAIN][entry.entry_id][ANDROID_DEV]
        await aftv.adb_close()
        hass.data[DOMAIN].pop(entry.entry_id)

    return unload_ok
type or paste code here

Why are you usin a custom component (copy?) for androidtv?
Nobody will be able to help with a version we know nothing about…

Why are you usin a custom component (copy?) for androidtv ?
Nobody will be able to help with a version we know nothing about…

I dont think I am, or at least I dont mean to be? I configured this a year ago and didnt take the best notes. I have since tried to reconfigure fresh and I am having the same issues?

Well, the message I highlighted says you do :wink:
The error paths (/config/custom_components/androidtv) also point to a custom component, obviously.

So how do I revert to something non custom? Again, I just dont remember how I set this up originally at all.

EDIT: Looks like I had an old “Hack” installed, I found it and was able to delete it. After reinstalling the integration things seem to be working.