comparison bot.py @ 91:69e4fc0f015c

Tried to fix XMPP «Replaced by new connection» problem Signed-off-by: Charly COSTE <changaco@changaco.net>
author Charly COSTE <changaco@changaco.net>
date Sun, 20 Sep 2009 16:10:52 +0200
parents 965dd6f5fcc3
children aae8870b3727
comparison
equal deleted inserted replaced
90:965dd6f5fcc3 91:69e4fc0f015c
102 except RuntimeError: 102 except RuntimeError:
103 pass 103 pass
104 except (xml.parsers.expat.ExpatError, xmpp.protocol.XMLNotWellFormed): 104 except (xml.parsers.expat.ExpatError, xmpp.protocol.XMLNotWellFormed):
105 self.error('=> Debug: invalid stanza', debug=True) 105 self.error('=> Debug: invalid stanza', debug=True)
106 unlock = True 106 unlock = True
107 except xmpp.Conflict:
108 c.reconnectAndReauth()
109 for m in c.mucs:
110 m.rejoin()
111 unlock = True
107 except: 112 except:
108 error = '[Error] Unkonwn exception on XMPP thread:\n' 113 error = '[Error] Unkonwn exception on XMPP thread:\n'
109 error += traceback.format_exc() 114 error += traceback.format_exc()
110 self.error(error, send_to_admins=True) 115 self.error(error, send_to_admins=True)
111 unlock = True 116 unlock = True