Module: deluge
Branch: master
Commit: b81159f295c41489ff53686d7a7efd9f1eaa8236

Author: Calum Lind <[email protected]>
Date:   Sat Jul  9 00:56:48 2011 +0100

Fix #1801: ConsoleUI failed connect missing error message

---

 deluge/ui/console/commands/connect.py |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/deluge/ui/console/commands/connect.py 
b/deluge/ui/console/commands/connect.py
index 010f6a7..18401f3 100644
--- a/deluge/ui/console/commands/connect.py
+++ b/deluge/ui/console/commands/connect.py
@@ -59,7 +59,11 @@ class Command(BaseCommand):
                 component.start()
 
             def on_connect_fail(result):
-                self.console.write("{!error!}Failed to connect to %s:%s with 
reason: %s" % (host, port, result.value.args[0]))
+                try:
+                    msg = result.value.exception_msg
+                except:
+                    msg = result.value.args[0]
+                self.console.write("{!error!}Failed to connect to %s:%s with 
reason: %s" % (host, port, msg))
 
             d.addCallback(on_connect)
             d.addErrback(on_connect_fail)

-- 
You received this message because you are subscribed to the Google Groups 
"deluge-commit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/deluge-commit?hl=en.

Reply via email to