Repository navigation
Add project selection to new Solo chats on mobile - #8546
Conversation
Co-authored-by: Terp <5856f6900e8e0a4e0ea1f4f8d2ee33e4753d2119bc122f94ecafc660b46c0511@buzz.block.builderlab.xyz> Signed-off-by: kenny lopez <klopez4212@gmail.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
🔐 Codex Security Review
Review SummaryOverall Risk: NONE
FindingsNo concrete security, correctness, or reliability findings were identified. Notes
Generated by Codex Security Review | |
jedwards27
left a comment
There was a problem hiding this comment.
:bot: Jude’s code review agent
Verdict: REQUEST CHANGES
Reviewed: 20ba95ed8906b2b7ae1819bdddadf82c09778097..a6ceb87e70e38005ec64a1c7f58517e9cfe576bf (exact head a6ceb87e70e38005ec64a1c7f58517e9cfe576bf)
Risk: medium — this changes a user-visible mobile Solo chat creation flow, the iOS native sheet bridge, and the durable pending-chat intent/placement path. No relay/schema/release contract change.
Behavior/contracts traced: Flutter new-chat project dropdown; iOS presentChat payload and native table sections; durable MeChatCreation restore/save/discard contract; _createMeChat placement into MeGroups.assignments; exact-head CI path filters and native Swift gate.
Findings:
- Blocking — the required native Swift CI gate is failing because the native-control test still inspects the old agent row section. The PR inserts the new Project row as chat section 1 and moves the agent row to section 2 (
mobile/ios/Runner/NativeProfileTextEditor.swift:537,mobile/ios/Runner/NativeProfileTextEditor.swift:571,mobile/ios/Runner/NativeProfileTextEditor.swift:601). The checked-in native-control test still fetchesIndexPath(row: 0, section: 1)and asserts agent-row button traits (mobile/ios/NativeControlTests/MeAgentAccessibilityTests.swift:21-24). On exact head,Mobile Swift Domain / Mobile Swift (Native)fails at generatedmain/test.swift:941, which maps back to that line 24 precondition, because the test is now looking at the Project row. Consequence: the exact-head required mobile native lane is red and the PR is blocked.
Author action: update the native-control test for the new section layout — at minimum assert the agent row at section 2, and preferably add a specific assertion for the new Project row at section 1 — then rerun/restore the required Mobile Swift Domain / Mobile Swift (Native) gate.
Verification owner: author + CI for the required native Swift gate. Reviewer/tooling owns any follow-up review on the next head.
Validation at exact head:
gh api user --jq .login→jedwards27; PR author isklopez4212, so normal review semantics apply.git rev-parse HEADinREPOS/buzz-pr-8546-carl→a6ceb87e70e38005ec64a1c7f58517e9cfe576bf; working tree clean before validation.flutter test test/features/channels/me/me_page_test.dart test/shared/me/me_chat_creation_test.dart test/features/channels/me/chat_preflight_test.dart --dart-define=BUZZ_PUSH_GATEWAY_URL=https://push.example— passed: 16/16.just mobile-check— passed:dart format --output=none --set-exit-if-changed .andflutter analyzefound no issues.- Exact-head CI run
39831905426for heada6ceb87e70e38005ec64a1c7f58517e9cfe576bf: mobile checks/tests/Android/release/result jobs passed, butMobile Swift Domain / Mobile Swift (Native)failed withmain/test.swift:941: Precondition failed.
Manual/native evidence: I did not independently run the iOS native sheet. The author reports installing Pairing Preview on iPhone Air and visually approving the form, with successful live chat creation still unverified because no agents were available. The repository native Swift gate is currently red, so that gate owns the concrete merge blocker.
Residual risk: successful live chat creation with a real available agent and selected project was not independently witnessed. That is a confidence gap, not the current author-actionable blocker; the blocker is the failing exact-head required native CI gate above. Any new head requires delta review.
Co-authored-by: Terp <5856f6900e8e0a4e0ea1f4f8d2ee33e4753d2119bc122f94ecafc660b46c0511@buzz.block.builderlab.xyz> Signed-off-by: kenny lopez <klopez4212@gmail.com>
jedwards27
left a comment
There was a problem hiding this comment.
🤖 :bot: Jude’s code review agent
Verdict: APPROVE
Reviewed: 20ba95ed8906b2b7ae1819bdddadf82c09778097..c85543637bedf6a966229b9022cff3c975da93bc
Prior reviewed head: a6ceb87e70e38005ec64a1c7f58517e9cfe576bf
Exact-head freshness: live PR head and local checkout both matched c85543637bedf6a966229b9022cff3c975da93bc; PR author is klopez4212; reviewing GitHub login is jedwards27.
No unresolved author-actionable defect remains.
Prior blocker
Resolved. The only delta from the previous reviewed head is mobile/ios/NativeControlTests/MeAgentAccessibilityTests.swift, and that test now covers the native sheet’s three sections, Project row at section 1, Agent row at section 2, Project accessibility label/value, locked/enabled behavior, and menu presence (mobile/ios/NativeControlTests/MeAgentAccessibilityTests.swift:21-33). The production native sheet uses the same Project/Agent section order (mobile/ios/Runner/NativeProfileTextEditor.swift:537-612).
Integrated review notes
- The mobile retry/persistence path stores the optional project in the encrypted chat-creation intent, saves before relay mutation, and treats a different project as a different pending intent (
mobile/lib/shared/me/me_chat_creation.dart:18-80,94-128). - The native flow carries the selected project into and out of the UIKit sheet, revalidates sync/account, revalidates agent ownership, validates the selected project against current Solo groups before mutation, and writes placement through encrypted Solo organization rather than channel metadata (
mobile/lib/features/channels/me/native_new_me_chat.dart:41-80,107-120,150-192;mobile/lib/shared/me/me_groups.dart:91-99). - The Flutter fallback places Project above agent selection, defaults to neutral “No project” behavior, preserves the typed chat name while changing projects, and disables project changes during busy/retry/frozen states (
mobile/lib/features/channels/me/new_me_chat.dart:46-164). - Empty/loading/error project states remain bounded for this scope because entry to New chat is gated on loaded Solo groups; failed project loading shows retry rather than opening a stale chooser (
mobile/lib/features/channels/me/me_page.dart:100-109;mobile/lib/features/channels/me/me_page_helpers.dart:3-13). - I found no new production
unwrap/expect/unsafe, no public API-doc issue, and no contradiction with the mobile vision requirement to preserve user-generated data across retries/restarts.
Validation
- Required GitHub checks at the exact head are green or path-skipped as expected, including
Mobile,DCO Check, andDesktop Release Candidate. Relevant mobile/native lanes passed in CI run39855628289:Clients / Mobile (Checks),Clients / Mobile (Tests 1/3..3/3),Clients / Mobile (Android),Mobile Swift Domain / Mobile Swift (Native), andMobile Swift Domain / Mobile Swift (Release). - Focused local validation run during review passed:
flutter test test/features/channels/me/me_page_test.dart test/shared/me/me_chat_creation_test.dart test/features/channels/me/chat_preflight_test.dart --dart-define=BUZZ_PUSH_GATEWAY_URL=https://push.example— PASS, 16/16.cd mobile && flutter test test/shared/me/me_chat_creation_test.dart test/features/channels/me/chat_preflight_test.dart --dart-define=BUZZ_PUSH_GATEWAY_URL=https://push.example— PASS, 8/8.cd mobile && flutter test test/features/channels/me/me_page_test.dart test/shared/me/me_groups_test.dart test/features/channels/me/solo_creation_tags_test.dart --dart-define=BUZZ_PUSH_GATEWAY_URL=https://push.example— PASS, 15/15.just mobile-check— PASS.scripts/test-mobile-me-agent-accessibility.sh <booted iOS simulator>— PASS:Me agent accessibility and bounded avatar loading passed.
Confidence gap
A live device chat creation with a real available agent/project was not manually completed. The source, widget tests, native-control test, and required mobile/native CI cover the retry/persistence/native-control seams; any additional live-device dogfood should be owned by release/manual smoke, not the PR author as a current blocker.
Author action: none.
## Summary Solo compose now opens before agent discovery finishes, and chat creation avoids full channel-list reloads while overlapping independent reads. Durable retries, ownership checks, and relay confirmation remain intact. The agent picker uses the owner's saved inventory, excludes known archived identities, verifies profiles off the UI thread, and reuses avatar artwork. ### Related issue No matching issue found. Related: #8546 adds project selection to the same compose surface. ### Testing - Full mobile suite: 3,755 passed, 19 skipped; four additional artifact tests passed. - Analysis, formatting, file-size checks, and iOS Release build passed. - Regression tests fail when the old blocking paths are restored. - Installed on a physical iPhone with existing profile/community settings preserved. Owner tested the earlier creation/picker improvements; final compose timing awaits device feedback. No timing recording captured. --------- Signed-off-by: kenny lopez <klopez4212@gmail.com> Co-authored-by: Terp <5856f6900e8e0a4e0ea1f4f8d2ee33e4753d2119bc122f94ecafc660b46c0511@buzz.block.builderlab.xyz>
New Solo chats can optionally choose a project in the Flutter form and native iOS sheet. Project appears above the agent picker with matching neutral text, and the choice survives retries and restarts.
Validation: full Flutter suite passed; analysis and iOS builds passed. Installed in Pairing Preview on iPhone Air and visually approved, preserving saved preferences. Successful live chat creation remains unverified because no agents were available.