diff --git a/NucleicRemote/NucleicRemote/Models/RemoteStore.swift b/NucleicRemote/NucleicRemote/Models/RemoteStore.swift index 91d286f..ead295a 100644 --- a/NucleicRemote/NucleicRemote/Models/RemoteStore.swift +++ b/NucleicRemote/NucleicRemote/Models/RemoteStore.swift @@ -783,6 +783,15 @@ final class RemoteStore: ObservableObject { openDiff = diff diffLoading = false case .wireError(let error): + // A channel mismatch is a permanent, connection-fatal condition (the host and this + // remote were built from incompatible release channels). Surface it as a persistent + // failure with a clear message rather than a transient bubble that the follow-on + // `.closed` would paper over with "reconnecting". + if error.code == .channelMismatch { + teardown() + connectivity = .failed(error.message) + break + } // Not fatal — surface as a transient bubble (the Mac's last-error overlay). // Losing an approval race isn't an error worth interrupting for; the card // collapses on the matching `approvalResolved`.