Fix GTK SIGABRT caused by dual reconnect racing into concurrent combo repopulation#18
Merged
Merged
Conversation
…ntWebsocket Agent-Logs-Url: https://github.com/gensyn/HomeAssistantPlugin/sessions/344bdc87-ab90-4a2f-ab5d-d93854508d0a Co-authored-by: gensyn <36128035+gensyn@users.noreply.github.com>
Copilot created this pull request from a session on behalf of
gensyn
April 16, 2026 09:52
View session
…ected Prevents the intermittent GTK crash (gtk_list_tile_split assertion, SIGABRT) caused by a race condition at startup: if the WebSocket connects fast enough, both StreamController's direct on_ready() call and _on_connect()'s GLib.idle_add(on_ready) land in the same GTK idle cycle before a frame render. This results in two populate() calls on the same ComboRow widget with different data, corrupting GTK's internal list-tile state. Fix: return early from BaseCore.on_ready() and PerformAction.on_ready() when the backend is not connected. _on_connect() already re-invokes on_ready() for every registered action once the connection is established, so all combos are populated exactly once with real data. Agent-Logs-Url: https://github.com/gensyn/HomeAssistantPlugin/sessions/1e729528-c030-4bd3-a769-497949a9b022 Co-authored-by: gensyn <36128035+gensyn@users.noreply.github.com>
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.
is_connected()guard inBaseCore.on_ready()to skip domain/entity loading when backend is not yet connected (prevents double-populate race at startup)is_connected()guard inPerformAction.on_ready()before_load_actions()/_reload()test_on_ready_not_connectedintest_perform_action_on_ready.pyto expect no loading calls when disconnected