Skip to content

Commit

Permalink
Add a name attribute to connection transport plugins
Browse files Browse the repository at this point in the history
  • Loading branch information
david415 committed Jun 1, 2016
1 parent d76aa4b commit 83b6605
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/foolscap/connection_plugins.py
Expand Up @@ -61,6 +61,7 @@ def convert_legacy_hint(location):

@implementer(IConnectionHintHandler, IPlugin)
class DefaultTCP(object):
name = "TCP"
def hint_to_endpoint(self, hint, reactor):
# Return (endpoint, hostname), where "hostname" is what we pass to the
# HTTP "Host:" header so a dumb HTTP server can be used to redirect us.
Expand All @@ -72,6 +73,7 @@ def hint_to_endpoint(self, hint, reactor):

@implementer(IConnectionHintHandler, IPlugin)
class SOCKS5(object):
name = "SOCKS5"
def __init__(self, endpoint=None, proxy_endpoint_factory=None):
if txsocksx is None:
raise PluginDependencyNotLoaded("""SOCKS5 foolscap client transport plugin requires txsocksx.\n
Expand Down

0 comments on commit 83b6605

Please sign in to comment.