SwiftUI: explain enabled-but-unreachable environments in the new-thread picker - #8621
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 9e6ff8e. Configure here.
ApprovabilityVerdict: Not approved Macroscope's review found this PR not approvable — This SwiftUI PR changes the default compose routing for no-project workspaces and adds a new unreachable-environment retry workflow across the workspace and project picker. Because it changes existing production behavior and introduces user-facing capability rather than an off-by-default option, human review is warranted. You can add or adjust custom eligibility rules. Learn more. |
Reconnecting is a transient state whose HTTP fallback still serves work, so announcing those environments as unreachable in the picker, empty state, and compose hint contradicted the sidebar and connection hub, which present reconnecting separately from offline. Only disconnected environments are unreachable now. Co-Authored-By: Claude <noreply@anthropic.com>

What users observed
In the SwiftUI iOS client, the environment picker on the new-thread screen enabled environments it could not actually reach. Picking one looked successful but the new thread then failed (or silently never started) — the picker gave no signal that the environment was enabled-but-unreachable.
Cause
The picker derived its enabled state only from the environment catalog; reachability (whether the environment's connection can actually serve a new thread) was not part of that decision, and no feedback existed for the unreachable case.
What changed
Affected: SwiftUI iOS client only — server, contracts, web/desktop, and React Native are unchanged.
Base:
t3code/rebuild-mobile-app-swiftatb67837984e5650888b1eed0e1cd7fff83625f696.UI changes
Before / after (mixed catalog, dark)
Before / after (no project, dark)
Interaction video
Play the mixed-catalog interaction video
Light-mode captures and the full set are embedded in the tracking issue.
Intentionally unchanged
Verification
T3CodeTests/DailyUXNewTaskTests(picker behavior, unreachable recovery, mutation evaluation) — run on this re-materialized head, iPhone 16 Pro / iOS 26.5 simulator; 80 test cases passed, 0 failed (xcodebuild exit 0).xcodebuild test, exit 0).git diff --checkclean.Known gaps / honest disclosures
Affected: SwiftUI iOS client only.
Note
Low Risk
SwiftUI-only UX and routing changes around environment connection display; no server or auth changes, with behavior locked by focused unit tests.
Overview
The SwiftUI iOS new task flow now explains when enabled environments cannot be reached, instead of silently failing or sending users straight to Add project.
Routing and semantics:
DailyUXCreationContextadds helpers that treat only enabled +.disconnectedenvironments as unreachable (.reconnectingstays usable via HTTP fallback).newTaskDestination(in:)opens the new-task screen when there are reachable projects or at least one such unreachable environment; otherwise it still routes to project creation. The workspace compose button uses the same logic and updates its accessibility hint for the three cases (has projects, unreachable-only, neither).UI: The empty No projects state in
NewThreadViewis scrollable and can list unreachable environments with warning styling, plus a single-flight Try again that callsmodel.reload()viaNewTaskRetryState. The project picker gains an Unavailable environments section (up to three visible names, full list in accessibility) that still appears when search returns no matches, driven byNewTaskProjectPickerPresentation.Tests:
DailyUXNewTaskTestscovers unreachable filtering, routing, retry state, and picker presentation.Reviewed by Cursor Bugbot for commit 77c3bf8. Bugbot is set up for automated code reviews on this repo. Configure here.
Note
Show enabled-but-unreachable environments in the new-thread picker
DailyUXCreationDestinationenum andDailyUXCreationContext.newTaskDestinationto route users to the new-task composer when there are unreachable environments, even with zero projects.NewTaskProjectPickerPresentationandNewTaskRetryStateto display up to 3 unreachable environments (with a "+N more" summary) and provide a single-flight retry button in NewThreadView.swift.unreachableEnvironmentsis defined as enabled environments whoseconnectionState == .disconnected; other transient states like.reconnectingare excluded.WorkspaceViewaccessibility hint and routing logic now adapt based on whether projects exist or environments are unreachable.openNewTaskOrProjectCreationnow opens the new-task composer instead of add-project when there are no projects but there are.disconnectedenabled environments; verify callers ofDailyUXCreationContext.newTaskDestinationhandle the.addProjectfallback.Macroscope summarized 77c3bf8.