mirror of
https://github.com/jonasbark/swiftcontrol.git
synced 2026-12-03 10:33:49 +01:00
Changing the control protocol cycles the bridge via ProxyDevice.reconnectUpstream, which rethrew a failed connectDevice. Every caller fires it from a UI callback nobody awaits (protocol select onChanged, "Use auto" button), so a DirCon host lookup failure (SocketException: Failed host lookup '<trainer>.local') surfaced as an uncaught "App crashed" error. Same for picking a bridge mode on the ConnectionCard of a disconnected trainer (_onSelect from onChanged). Both now record the error via recordError and alert the rider; Connection._connect has already logged it and reset the device, and the usual rediscovery reconnects the trainer. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>