aaf63220ca
migrateV1ToRegistry runs exactly once, only when connections.json is absent. A user who was local at that moment and pointed Settings -> Gateway at a remote afterwards gets a live remote the registry cannot name: the descriptor resolves to no connectionId, primary still says 'local', and the boot-time launch pick force-switches the window onto a fresh local backend seconds after the sessions list paints. That backend has no provider, so onboarding pops. Reconcile on read: when the v1 global route names a remote with no matching registry entry, register it and adopt it as primary/last-used, then persist so the repair happens once. Narrow on purpose — an already-registered route is left alone even when primary names something else, because that is the user's pick in the Connections panel, not drift. Replaces the hand-edit-connections.json workaround users have been trading.