-
-
Notifications
You must be signed in to change notification settings - Fork 30.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix name of emby media player #32183
Fix name of emby media player #32183
Conversation
return ( | ||
f"Emby - {self.device.client} - {self.device.name}" or DEVICE_DEFAULT_NAME | ||
) | ||
return f"Emby {self.device.client} {self.device.name}" or DEVICE_DEFAULT_NAME |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove the client name completely.
The person who reported that issue is having an invalid entity in their entity registry. That can no longer happen and this PR won't fix the error. I still think we should merge this PR and drop the client name, as that's an implementation detail. |
The client name was originally added to make the entity description as unique as possible. You can change the device name within emby but not the client name (androidtv, roku, etc) so it made it easy to distinguish your devices. That being said, I don't have a problem with removing it, but it would make this a breaking change since entity names will change for all emby media players. |
Curious do we have any documentation on how to delete an invalid entity in the entity registry? |
@mezz64 this is not a breaking change because the entity has a unique ID, so it will only impact the entity ID of new entities. |
Codecov Report
@@ Coverage Diff @@
## dev #32183 +/- ##
==========================================
- Coverage 94.75% 94.75% -0.01%
==========================================
Files 768 768
Lines 55639 55646 +7
==========================================
+ Hits 52722 52725 +3
- Misses 2917 2921 +4
Continue to review full report at Codecov.
|
Thanks for the refresher. I completely forgot that entity registry rules all now. |
Breaking change
Proposed change
Small fix for the below mentioned issue. Emby integration tries to create an entity with the following entity_id
media_player.emby__pyemby__homeassistant
.This fails since words should only be separated by one
_
. Moreover, the client name is removed as well since it is not necessary.Now the following entity_id is created successfully
media_player.emby_homeassistant
.Type of change
Example entry for
configuration.yaml
:Additional information
Checklist
black --fast homeassistant tests
)If user exposed functionality or configuration variables are added/changed:
If the code communicates with devices, web services, or third-party tools:
Updated and included derived files by running:
python3 -m script.hassfest
.requirements_all.txt
.Updated by running
python3 -m script.gen_requirements_all
..coveragerc
.The integration reached or maintains the following Integration Quality Scale: