Hide Huddles in mobile agent DMs - #6676
Conversation
Signed-off-by: kenny lopez <klopez4212@gmail.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 6f729de6c0
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Signed-off-by: kenny lopez <klopez4212@gmail.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8dc06559a3
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Signed-off-by: kenny lopez <klopez4212@gmail.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 61918ccf78
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| final memberProfilesPreload = useMemoized( | ||
| () => _preloadMembers(ref, resolvedChannel.id), | ||
| [resolvedChannel.id], | ||
| ); |
There was a problem hiding this comment.
Rerun profile resolution after reconnect
When this page first resolves members while disconnected or after a failed member lookup, _preloadMembers completes without loading profiles; reconnecting later invalidates channelMembersProvider, but this memoized future is keyed only by the unchanged channel ID and never runs again. The DM header can start a separate profile preload after reconnect, yet memberProfilesPreloadState already reports done, so a verified-owner-only agent DM can briefly expose the Huddle action once the directory and bot queries settle but before that profile fetch finishes. Fresh evidence after the earlier fix is that the new awaitable preload is still memoized without any session/member-provider generation dependency.
Useful? React with 👍 / 👎.
| final channelBotPubkeysState = ref.watch( | ||
| channelBotPubkeysProvider(resolvedChannel.id), | ||
| ); |
There was a problem hiding this comment.
Subscribe to bot-role updates with the d tag
When a participant gains the bot role while this DM page remains mounted, the new gate keeps using the initially fetched human classification: channelBotPubkeysProvider depends on _ChannelBotRoleSubscription, whose kind:39002 subscription filters on #h, while the relay's membership snapshots identify the channel with d and therefore never match it. As a result the Huddle action remains visible until navigation or reconnection forces a refetch; subscribe with #d (or otherwise invalidate from the actual membership event).
AGENTS.md reference: AGENTS.md:L180-L185
Useful? React with 👍 / 👎.
Summary
Testing