You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Channel list doesn't refresh when channels are removed/added on gateway #55
When a channel is removed or disabled on the gateway server (e.g., removing a Discord channel config), the Windows tray UI continues showing the channel with its last known status (green/red dot). There's no mechanism to detect that a channel has been removed — only status changes for existing channels are tracked.
Current behavior
Channel list is refreshed on health check (every 30 seconds)
Health check returns the current set of channels from channels.health
But the UI merges/updates the existing list — it doesn't detect removed channels
Expected behavior
If a channel disappears from the gateway's channels.health response, it should be removed from the UI
If a channel is added on the gateway, it should appear in the UI on the next health check
The tray menu and Status Detail window should both reflect the current set
Suggested approach
Compare the incoming channel list with _lastChannels on each health check update:
Channels in the response but not in _lastChannels → add
Channels in _lastChannels but not in the response → remove
Replace the full list rather than merging
This should be a small change in App.xaml.cs where ChannelHealthUpdated is handled.
Good catch! I dug into the code and found two distinct root causes:
1. Empty channel list is silently dropped (OpenClawGatewayClient.cs)
ParseChannelHealth has a guard if (healthList.Count > 0) that suppresses the ChannelHealthUpdated event when the gateway returns an empty channel object. This means removing the last channel never clears _lastChannels.
2. Open StatusDetailWindow never receives live updates (App.xaml.cs)
OnChannelHealthUpdated does _lastChannels = channels (which is a full replacement — added/removed channels are handled correctly for the tray menu), but it never pushes the new list to an already-open StatusDetailWindow. The window only gets refreshed when the user reopens it.
I've created a PR that fixes both issues — see the linked draft PR.
Activity
github-actions commentedon Mar 17, 2026
🤖 This is an automated response from Repo Assist.
Good catch! I dug into the code and found two distinct root causes:
1. Empty channel list is silently dropped (
OpenClawGatewayClient.cs)ParseChannelHealthhas a guardif (healthList.Count > 0)that suppresses theChannelHealthUpdatedevent when the gateway returns an empty channel object. This means removing the last channel never clears_lastChannels.2. Open StatusDetailWindow never receives live updates (
App.xaml.cs)OnChannelHealthUpdateddoes_lastChannels = channels(which is a full replacement — added/removed channels are handled correctly for the tray menu), but it never pushes the new list to an already-openStatusDetailWindow. The window only gets refreshed when the user reopens it.I've created a PR that fixes both issues — see the linked draft PR.
fix: refresh channel list when channels are added/removed on gateway
[Repo Assist] fix: refresh channel list when channels are added/remov…
fix: refresh channel list when channels are added/removed on gateway