Skip to content
Browse files

ignore ConnectionRefusedError too

  • Loading branch information...
warner committed Aug 12, 2019
1 parent 2e2120f commit 854f0d6e011c0a692678fc8d6a1e7a4dc56e3a94
Showing with 4 additions and 2 deletions.
  1. +4 −2 src/wormhole/_dilation/
@@ -10,7 +10,7 @@
from twisted.internet.endpoints import serverFromString
from twisted.internet.protocol import ClientFactory, ServerFactory
from twisted.internet.address import HostnameAddress, IPv4Address, IPv6Address
from twisted.internet.error import ConnectingCancelledError, DNSLookupError
from twisted.internet.error import ConnectingCancelledError, ConnectionRefusedError, DNSLookupError
from twisted.python import log
from .. import ipaddrs # TODO: move into _dilation/
from .._interfaces import IDilationConnector, IDilationManager
@@ -312,7 +312,9 @@ def _schedule_connection(self, delay, h, is_relay):
d = deferLater(self._reactor, delay,
self._connect, ep, desc, is_relay)
d.addErrback(lambda f: f.trap(ConnectingCancelledError,
# TODO: HostnameEndpoint.connect catches CancelledError and replaces
# it with DNSLookupError. Remove this workaround when
# is fixed.

0 comments on commit 854f0d6

Please sign in to comment.
You can’t perform that action at this time.