mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-04-26 13:59:59 +00:00
Slightly better user-facing privacy error message here
This commit is contained in:
parent
9259264d27
commit
efac902e57
@ -654,7 +654,10 @@ def create_default_connection_handlers(reactor, config, handlers):
|
|||||||
|
|
||||||
if not reveal_ip:
|
if not reveal_ip:
|
||||||
if default_connection_handlers.get("tcp") == "tcp":
|
if default_connection_handlers.get("tcp") == "tcp":
|
||||||
raise PrivacyError("tcp = tcp, must not be set to 'tcp'")
|
raise PrivacyError(
|
||||||
|
"Privacy requested with `reveal-IP-address = false` "
|
||||||
|
"but `tcp = tcp` conflicts with this.",
|
||||||
|
)
|
||||||
return default_connection_handlers
|
return default_connection_handlers
|
||||||
|
|
||||||
|
|
||||||
|
@ -412,7 +412,8 @@ class Privacy(unittest.TestCase):
|
|||||||
|
|
||||||
self.assertEqual(
|
self.assertEqual(
|
||||||
str(ctx.exception),
|
str(ctx.exception),
|
||||||
"tcp = tcp, must be set to 'tor' or 'disabled'",
|
"Privacy requested with `reveal-IP-address = false` "
|
||||||
|
"but `tcp = tcp` conflicts with this.",
|
||||||
)
|
)
|
||||||
|
|
||||||
def test_connections_tcp_disabled(self):
|
def test_connections_tcp_disabled(self):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user