fix: clarify remote gateway error
This commit is contained in:
@@ -185,12 +185,19 @@ final class ControlChannel {
|
|||||||
case .cancelled:
|
case .cancelled:
|
||||||
return "Gateway connection was closed; start the gateway (localhost:\(port)) and retry."
|
return "Gateway connection was closed; start the gateway (localhost:\(port)) and retry."
|
||||||
case .cannotFindHost, .cannotConnectToHost:
|
case .cannotFindHost, .cannotConnectToHost:
|
||||||
if AppStateStore.attachExistingGatewayOnly {
|
let isRemote = CommandResolver.connectionModeIsRemote()
|
||||||
|
if AppStateStore.attachExistingGatewayOnly, !isRemote {
|
||||||
return """
|
return """
|
||||||
Cannot reach gateway at localhost:\(port) and “Attach existing gateway only” is enabled.
|
Cannot reach gateway at localhost:\(port) and “Attach existing gateway only” is enabled.
|
||||||
Disable it in Debug Settings or start a gateway on that port.
|
Disable it in Debug Settings or start a gateway on that port.
|
||||||
"""
|
"""
|
||||||
}
|
}
|
||||||
|
if isRemote {
|
||||||
|
return """
|
||||||
|
Cannot reach gateway at localhost:\(port).
|
||||||
|
Remote mode uses an SSH tunnel—check the SSH target and that the tunnel is running.
|
||||||
|
"""
|
||||||
|
}
|
||||||
return "Cannot reach gateway at localhost:\(port); ensure the gateway is running."
|
return "Cannot reach gateway at localhost:\(port); ensure the gateway is running."
|
||||||
case .networkConnectionLost:
|
case .networkConnectionLost:
|
||||||
return "Gateway connection dropped; gateway likely restarted—retry."
|
return "Gateway connection dropped; gateway likely restarted—retry."
|
||||||
|
|||||||
Reference in New Issue
Block a user