mirror of
https://git.deluge-torrent.org/deluge
synced 2025-08-02 22:48:40 +00:00
Fix issue where trying to handle an announce alert after the torrent has
been removed from session.
This commit is contained in:
parent
c5eba92174
commit
1a8c3d21be
1 changed files with 6 additions and 1 deletions
|
@ -662,7 +662,12 @@ class TorrentManager(component.Component):
|
||||||
def on_alert_tracker_announce(self, alert):
|
def on_alert_tracker_announce(self, alert):
|
||||||
log.debug("on_alert_tracker_announce")
|
log.debug("on_alert_tracker_announce")
|
||||||
# Get the torrent_id
|
# Get the torrent_id
|
||||||
torrent_id = str(alert.handle.info_hash())
|
try:
|
||||||
|
torrent_id = str(alert.handle.info_hash())
|
||||||
|
except RuntimeError:
|
||||||
|
log.debug("Invalid torrent handle.")
|
||||||
|
return
|
||||||
|
|
||||||
# Set the tracker status for the torrent
|
# Set the tracker status for the torrent
|
||||||
try:
|
try:
|
||||||
self.torrents[torrent_id].set_tracker_status(_("Announce Sent"))
|
self.torrents[torrent_id].set_tracker_status(_("Announce Sent"))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue