From 46ff7dd4e2e6555beb9b648dae89fa7b1cf33255 Mon Sep 17 00:00:00 2001 From: Safihre Date: Fri, 25 Sep 2020 10:03:05 +0200 Subject: [PATCH] Do not crash if we can't save attributes, the job might be gone --- sabnzbd/nzbqueue.py | 3 +-- sabnzbd/nzbstuff.py | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/sabnzbd/nzbqueue.py b/sabnzbd/nzbqueue.py index 1b04ddc..747139f 100644 --- a/sabnzbd/nzbqueue.py +++ b/sabnzbd/nzbqueue.py @@ -776,10 +776,9 @@ class NzbQueue: def end_job(self, nzo): """ Send NZO to the post-processing queue """ - logging.info("[%s] Ending job %s", caller_name(), nzo.final_name) - # Notify assembler to call postprocessor if not nzo.deleted: + logging.info("[%s] Ending job %s", caller_name(), nzo.final_name) nzo.deleted = True if nzo.precheck: nzo.save_to_disk() diff --git a/sabnzbd/nzbstuff.py b/sabnzbd/nzbstuff.py index 842dc86..5c3f17e 100644 --- a/sabnzbd/nzbstuff.py +++ b/sabnzbd/nzbstuff.py @@ -1891,7 +1891,7 @@ class NzbObject(TryList): for attrib in NzoAttributeSaver: attribs[attrib] = getattr(self, attrib) logging.debug("Saving attributes %s for %s", attribs, self.final_name) - sabnzbd.save_data(attribs, ATTRIB_FILE, self.workpath) + sabnzbd.save_data(attribs, ATTRIB_FILE, self.workpath, silent=True) def load_attribs(self): """ Load saved attributes and return them to be parsed """