improve sync error messages

This commit is contained in:
Damien Elmes 2010-12-07 16:48:05 +09:00
parent 060fbb788e
commit ccc91b364e

View file

@ -73,6 +73,16 @@ class Sync(QThread):
self.emit(SIGNAL("badUserPass")) self.emit(SIGNAL("badUserPass"))
elif error.data.get('status') == "oldVersion": elif error.data.get('status') == "oldVersion":
msg=_("The sync protocol has changed. Please upgrade.") msg=_("The sync protocol has changed. Please upgrade.")
elif error.data.get('type') == 'noResponse':
msg=_("""\
The server didn't reply. Please try again shortly, and if the problem \
persists, please report it on the forums.""")
elif error.data.get('type') == 'connectionError':
msg=_("""\
There was a connection error. If it persists, please try disabing your
firewall software temporarily, or try again from a different network.
Debugging info: %s""") % error.data.get("exc", "<none>")
else: else:
tb = traceback.format_exc() tb = traceback.format_exc()
if "missingFacts" in tb: if "missingFacts" in tb: