Core: Doubled media players entities

Created on 8 Jun 2017  路  9Comments  路  Source: home-assistant/core

Make sure you are running the latest version of Home Assistant before reporting an issue.

You should only file an issue if you found a bug. Feature and enhancement requests should go in the Feature Requests section of our community forum:

Home Assistant release (hass --version):
0.46

Python release (python3 --version):
Python 3.4.2

Component/platform:
media_player & discovery

Description of problem:
I have in configuration two media players:

- platform: denonavr
  host: denon.local
  name: Denon
- platform: cast
  host: androidtv.local

denon.local and androidtv.local are a local domain names. With this configuration I have doubled media players entities:
double_media_players
When I change local domain names to IP address or turn off discovery component there is only one entity for one media player.

Expected:
Only one entity for one media player with local domain host names.

waiting-for-reply

All 9 comments

I think you solved your own problem, remove discovery and use manual config, or use discovery and remove manual config. Use both, get both.

Yes, I know that I have solution for this problem but I believe this is not the correct behavior of the Home Assistant.

I think discovery can never know your local domain information, so it can only ignore discovery on ip addresses you've set elsewhere in the configuration.

I'm still not sure why you would use both discovery and manual configuration for devices discovery discovers though?

I use discovery for other devices that only occasionally appear on the network.

Yes, so either use discovery to discover your media centres as well (and remove the manual entries) - or use the ignore option in the discovery component to prevent duplication if you need to set further options manually.

The ignore option is a good idea. I didn't know it before. Thanks.

I think that if the entity would override the unique_id property, double entries would not be created.
(i.e. the problem would be solved if the mediaplayer.cast and mediaplayer.denon components implemented the unique_id property to return something like the mac address or something. In that way hass would recognize the device being the same the second time it is created and skipped instead).

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates.

Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment :+1:

This issue will be auto-closed because there hasn't been any activity for a few months. Feel free to open a new one if you still experience this problem 馃憤

Was this page helpful?
0 / 5 - 0 ratings

Related issues

raccettura picture raccettura  路  142Comments

rschaeuble picture rschaeuble  路  230Comments

winterscar picture winterscar  路  251Comments

soldag picture soldag  路  143Comments

kdschlosser picture kdschlosser  路  374Comments