Skip to content

perf(mobile): watch Solo agent names only in Solo chats - #9324

Draft
brow wants to merge 1 commit into
loganj/mobile-solo-agent-namesfrom
solo-names-rebuild-fix
Draft

brow wants to merge 1 commit into
loganj/mobile-solo-agent-namesfrom
solo-names-rebuild-fix

Conversation

@brow

@brow brow commented Nov 10, 2026 •

Copy link
Copy Markdown
Collaborator

Follow-up to #9321, targeting its branch (rebased onto its head 6bd0894).

What

useMeChatAssistant runs on every channel page. On #9321's head it called watchMeAssistantNames (which watches the whole profile cache and verified names) even when enabled is false, so every profile load rebuilt every channel, DM and forum page and copied the full profile map. It now watches names only when the hook is enabled (Solo chats), and named() returns false otherwise.

(#9321's 6bd0894 already fixed the Me-list rows, so this PR no longer touches me_working_provider.dart.)

Why nothing gets worse

Labels are the same wherever they show. Outside Solo, selected and the pending change are always null, so names were never read there: name stays profile?.displayName as on the merge-base. In Solo the code path is unchanged, including labels for saved archived agents.

Validation

  • Test: extends the existing activity in another channel does not rebuild the open chat journey (channel_detail_page_test.dart) with a step: an unrelated profile load must not rebuild the open channel page. It fails with fix(mobile): tell same-name agents apart in Solo #9321's lib/ at 6bd0894 and passes with this fix.
  • flutter analyze on the touched files: no issues. Full just mobile-test passed on this change (4,619 Flutter tests, 73 skipped, plus the push and crypto suites).
  • No visible change, so no screenshots. No device run: behavior is unchanged where visible, and the risk is rebuild count, which the widget test covers.

🤖 Generated with Claude Code

@brow

brow commented Nov 10, 2026

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-10T16:31:05.740770Z 540fbd6 Manual request
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. You're on a roll.

Reviewed commit: 540fbd6040

ℹ️ 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".

The chat header hook runs on every channel page, and it watched every
identity name source even outside Solo, so any profile load rebuilt the
whole page. Watch names only when the hook is enabled, and bind the guard
to the existing channel isolation journey: an unrelated profile load must
not rebuild the open channel page.

Co-authored-by: corey <2dafccf60ea6d431a568f6d67fc600160d92a51e415e09dc8b213b8e360663d5@localhost>
Co-authored-by: studio <dc2fc481343672df31a689840c09299972e704dac592e0da6f18486646a7ee3e@localhost>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tom Brow <tomb@squareup.com>
@brow
brow force-pushed the solo-names-rebuild-fix branch from 5d03bc9 to 3b7b4a1 Compare November 10, 2026 19:12
@brow brow changed the title perf(mobile): watch Solo agent names only where agents are offered perf(mobile): watch Solo agent names only in Solo chats Nov 10, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants