Sync groups: keep slaved followers in group member dropdown after removal#4036
Open
MarvinSchenkel wants to merge 2 commits into
Open
Sync groups: keep slaved followers in group member dropdown after removal#4036MarvinSchenkel wants to merge 2 commits into
MarvinSchenkel wants to merge 2 commits into
Conversation
… removal When a member is removed from a sync group config during active playback it remains slaved at the protocol level (synced_to is non-None) but its can_group_with returns empty (players already synced cannot group with others). Since the player is no longer in saved_ids and can_group_with is empty, it disappeared from the group member dropdown making it impossible to re-add without stopping playback first. Fix by also including players whose synced_to is set: a synced follower is still group-capable, it is just temporarily occupied. Fixes: music-assistant/support#5559
… removal When a member is removed from a sync group config during active playback it remains slaved at the protocol level (synced_to is non-None) but its can_group_with returns empty (players already synced cannot group with others). Since the player is no longer in saved_ids and can_group_with is empty, it disappeared from the group member dropdown making it impossible to re-add without stopping playback first. Fix by also including players whose synced_to is set: a synced follower is still group-capable, it is just temporarily occupied. Fixes: music-assistant/support#5559
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes a UI regression where a sync-group member removed mid-playback disappeared from the "Group members" dropdown because its can_group_with was empty while still slaved at the protocol level.
Changes:
- Extends the member-picker condition in
SyncGroupPlayer.get_config_entries()to also include players that are currently synced followers (x.state.synced_to).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this implement/fix?
When a member is removed from a sync group config during active playback, it remains slaved at the protocol level (
synced_tois non-None). Because a synced follower'scan_group_withreturns an empty set (players already synced cannot group with others), and the player is no longer insaved_ids(it was just removed from config), it disappeared entirely from the "Group members" dropdown — making it impossible to re-add without stopping playback first.The fix adds
or x.state.synced_toto theget_config_entries()member-picker condition. A player withSET_MEMBERSsupport that is currently a synced follower is still group-capable; it is just temporarily occupied. This matches the intent of the existingsaved_idsfallback (which was added to prevent the same class of disappearing-player bug during active playback).Related issue (if applicable):
Types of changes
bugfixnew-featureenhancementnew-providerbreaking-changerefactordocumentationmaintenancecidependenciesChecklist
pre-commit run --all-filespasses.pytestpasses, and tests have been added/updated undertests/where applicable.music-assistant/modelsis linked.music-assistant/frontendis linked.Generated by Claude Code