Browse Source

Correct handeling of TryList when server has timeout

tags/2.3.0Alpha1
Safihre 8 years ago
parent
commit
8c42237d51
  1. 7
      sabnzbd/downloader.py
  2. 4
      sabnzbd/nzbqueue.py

7
sabnzbd/downloader.py

@ -791,11 +791,8 @@ class Downloader(Thread):
# Remove this server from try_list # Remove this server from try_list
article.fetcher = None article.fetcher = None
nzf = article.nzf # Allow all servers to iterate over each nzo/nzf again
nzo = nzf.nzo sabnzbd.nzbqueue.NzbQueue.do.reset_try_lists(article.nzf, article.nzf.nzo)
# Allow all servers to iterate over each nzo/nzf again ##
sabnzbd.nzbqueue.NzbQueue.do.reset_try_lists(nzf, nzo)
if destroy: if destroy:
nw.terminate(quit=quit) nw.terminate(quit=quit)

4
sabnzbd/nzbqueue.py

@ -857,7 +857,9 @@ class NzbQueue(object):
""" Detect jobs that have zero files left or are stalled """ Detect jobs that have zero files left or are stalled
and send them to post-processing and send them to post-processing
""" """
nr_servers = len(sabnzbd.downloader.Downloader.do.servers) # Only active servers that are not on time-out
nr_servers = len([server for server in sabnzbd.downloader.Downloader.do.servers if server.active])
empty = [] empty = []
for nzo in self.__nzo_list: for nzo in self.__nzo_list:
if not nzo.futuretype and nzo.status not in (Status.PAUSED, Status.GRABBING): if not nzo.futuretype and nzo.status not in (Status.PAUSED, Status.GRABBING):

Loading…
Cancel
Save