fix(desktop): stop auto-opting users into v2 + onboarding
Merged
SA
6mo ago+0+0+0123456789-82-82-01234567890123456789
Summary
- Fresh installs were being auto-flipped to
optInV2: trueand then force-walked through the experimental/setup/*onboarding flow on first launch. Both behaviors are removed — v2 and onboarding are explicit-opt-in only via Settings → Experimental. - Deletes
V2DefaultResolver,useIsFreshInstall, theisFreshInstallstore field, the redirect block in_authenticated/layout.tsx, and theprojects.hasAny/workspaces.hasAnytRPC procedures (all unused once the auto-flip is gone). - Preserves the v2 toggle and "Restart onboarding" action in Settings → Experimental, the full
/setup/*route tree, and any persistedoptInV2: truefrom users who explicitly toggled.
Test plan
- Fresh install (clear
v2-local-override-v2localStorage): launches into v1 dashboard, no/setup/*redirect. - Existing v1 user (projects/workspaces in localdb, no persisted override): stays on v1.
- User who toggled v2 on under Settings → Experimental: stays on v2 across launches, lands on the dashboard (not setup).
- Settings → Experimental → "Restart onboarding" still walks through
/setup/providers→ ... when v2 is on. - Toggle v2 off in Experimental: surface flips back to v1 immediately.
Summary by cubic
Stops auto-opting fresh installs into v2 and removes the forced /setup/* onboarding. v2 and onboarding are now explicit opt-in via Settings → Experimental; all users land on the dashboard.
-
Bug Fixes
- Removed first-launch redirect to
/setup/*and the fresh-install auto-set of v2. - Kept existing
optInV2values inv2-local-override-v2to avoid resetting explicit opt-ins; recently auto-flipped installs will remain on v2 unless toggled off.
- Removed first-launch redirect to
-
Refactors
- Deleted
V2DefaultResolver,useIsFreshInstall, and theisFreshInstallfield from thev2-local-overridestore. - Removed unused tRPC procedures
projects.hasAnyandworkspaces.hasAny.
- Deleted
Summary by CodeRabbit
-
Refactor
- Removed fresh-install detection and its initialization flow
- Persisted workspace list now respects tab order
- Local defaults state simplified to only store opt-in choice
- Removed several unused internal query endpoints and re-exports
-
Bug Fix
- Eliminated an onboarding redirect that relied on the removed fresh-install logic