From 712570847b88fe754c3fd4cb9e42bf3b354c3fe4 Mon Sep 17 00:00:00 2001 From: Jon Bergli Heier Date: Tue, 25 May 2010 19:58:18 +0200 Subject: Print sane error messages in BotFactory's failed and lost handlers. --- fot.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'fot.py') diff --git a/fot.py b/fot.py index 2fedee6..6ed05c0 100755 --- a/fot.py +++ b/fot.py @@ -110,11 +110,11 @@ class BotFactory(protocol.ReconnectingClientFactory): print 'Connecting to', connector.host def clientConnectionFailed(self, connector, reason): - print 'Connection failed:', reason + print 'Connection failed:', reason.getErrorMessage() protocol.ReconnectingClientFactory.clientConnectionFailed(self, connector, reason) def clientConnectionLost(self, connector, reason): - print 'Connection lost:', reason + print 'Connection lost:', reason.getErrorMessage() protocol.ReconnectingClientFactory.clientConnectionLost(self, connector, reason) def start_server(server): -- cgit v1.2.3