Remove duplicate Apple TV

Nothing in the log.

So you see it in the web interface but not in the log? If you search for just apple_tv?

I only had errors being logged. Will turn that off. Sorry…

Yes, I can see it now. Lots of entries, but apple_tv_2 has appeared again. Man this is so confusing.

Do you use plex on the Apple TV?

If so won’t plex just be creating the other media.player.appletv?

If you can set up entity namespace for all your media_player configs then I think this mystery media player might get renamed…

media_player.plex_appletv

(Apologies if this is what you tried already, I am getting a cold so head is feeling a bit fuggy at the moment!)

OK added a entity_namepsace to the manually specified Apple_TV in media_players.yaml and I have identified this in fact creates the old style attributes. The auto discovered platform in fact is showing the new style attributes!

I am not sure what is going on but that is looking very different to what I got earlier.

I think I need to reset all this and try again.

I am a bit confused, and perhaps don’t understand what exactly is the issue, but have you applied entity namespace to all your media players, not just Apple TV?

For example until I set up entity namespace my nvidia shield tv was discovered as a player by both plex & chromecast so created 2 media players…

media_player.shield
media_player.shield1

It wasn’t until I set entity namespace that I could get them to differentiate as…

media_player.plex_shield
media_player.cast_shield

I assumed that what you are seeing is the same, that the Apple TV & plex are both creating a player. The plex one will automatically use the device name, which I guess just happens to be “appletv”

I might be completely wrong though!!!

Sorry for causing confusion!

I have added a unique namespace to the apple_tv in media_players.yaml and restarted HA. This unique namespace is the only listed apple entity when first turned on.

Now I run BBC iPlayer on my Apple TV and that is detected OK and all the attributes are populated OK. Nothing else appears.

Now I run Plex on the Apple TV and immediately another entity appears media_player.apple_tv alongside the existing unique one above. So it seems when running plex it does create another entity. Both now remain permanently until I restart HA and then reverts to only having only the unique one from above until I start Plex again.

Yes, so it is plex creating the other media player - it is not a duplicate, it is a separate thing. One media player is created by the appletv platform & one by the plex platform.

So if you assign entity namespace to plex as well it would now be called…

media_player.plex_appletv

If you were to install Kodi on your appletv, and then add the kodi platform to home assistant you’d probably get another one called…

media_player.appletv_3