Commit 1bd9d8e5 authored by Yann Leboulanger's avatar Yann Leboulanger

improve error message when we cannot connect to a host via a proxy. Fixes #7358

parent a64c8bc8
......@@ -1262,7 +1262,12 @@ def _connect_failure(self, con_type=None):
# we are not retrying, and not conecting
if not self.retrycount and self.connected != 0:
self.disconnect(on_purpose = True)
pritxt = _('Could not connect to "%s"') % self._hostname
if self._proxy:
pritxt = _('Could not connect to "%(host)s" via proxy "%(proxy)s"') %\
{'host': self._hostname, 'proxy': self._proxy['host']}
pritxt = _('Could not connect to "%(host)s"') % {'host': \
sectxt = _('Check your connection or try again later.')
if self.streamError:
# show error dialog
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment