Android TV notifications - error during setup

Hello,
any idea how to resolve this issue? I have Notification App already installed on my TV.

Logger: homeassistant.setup
Source: components/nfandroidtv/__init__.py:23
First occurred: 21:05:53 (1 occurrences)
Last logged: 21:05:53

Error during setup of component nfandroidtv
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/setup.py", line 235, in _async_setup_component
    result = await task
  File "/usr/src/homeassistant/homeassistant/components/nfandroidtv/__init__.py", line 23, in async_setup
    if entry[CONF_PLATFORM] == DOMAIN:
TypeError: string indices must be integers

Thank you.

Hi, I had the same issue. I solved it by commented out another notify configuration in my configuration.yaml

Looks like this peace of code is failing when another notify is present.

 # Iterate all entries for notify to only get nfandroidtv
    if NOTIFY in config:
        for entry in config[NOTIFY]:
            if entry[CONF_PLATFORM] == DOMAIN:
                hass.async_create_task(
                    hass.config_entries.flow.async_init(
                        DOMAIN, context={"source": SOURCE_IMPORT}, data=entry
                    )
                )

For reference, this was the config I commented out:

notify:
  name: "Computer"
  platform: hass_agent_notifier
  resource: http://192.168.50.20:5115/notify
1 Like

Worked! :partying_face:
Thank you!

This will fix the error without needing to remove hass_agent_notifier:

notify:
  - name: "Computer"
    platform: hass_agent_notifier
    resource: http://192.168.50.20:5115/notify
1 Like