mirror of
https://github.com/codex-storage/deluge.git
synced 2025-01-11 12:04:10 +00:00
Fix display of tracker error messages
This commit is contained in:
parent
a7f1704c28
commit
e250b7aaf4
@ -700,8 +700,7 @@ class TorrentManager(component.Component):
|
||||
def on_alert_tracker_error(self, alert):
|
||||
log.debug("on_alert_tracker_error")
|
||||
torrent = self.torrents[str(alert.handle.info_hash())]
|
||||
error_msg = " ".join(alert.message().split()[3:]).split(":")[0]
|
||||
tracker_status = "%s: %s" % (_("Error"), error_msg)
|
||||
tracker_status = "%s: %s" % (_("Error"), alert.msg)
|
||||
try:
|
||||
torrent.set_tracker_status(tracker_status)
|
||||
except KeyError:
|
||||
|
@ -104,6 +104,7 @@ void bind_alert()
|
||||
class_<tracker_error_alert, bases<tracker_alert>, noncopyable>(
|
||||
"tracker_error_alert", tracker_error_alert_doc, no_init
|
||||
)
|
||||
.def_readonly("msg", &tracker_error_alert::msg)
|
||||
.def_readonly("times_in_row", &tracker_error_alert::times_in_row)
|
||||
.def_readonly("status_code", &tracker_error_alert::status_code)
|
||||
;
|
||||
|
Loading…
x
Reference in New Issue
Block a user