diff --git a/Changelog.yaml b/Changelog.yaml index ca5f7ee280..add0a1bcf5 100644 --- a/Changelog.yaml +++ b/Changelog.yaml @@ -43,6 +43,9 @@ tickets: [3328] - title: "Linux device detection: Switch to using libusb1 to enumerate devices on system." + description: > + "If you are building for source, the libusb1 headers and library are now required at + compile time." bug fixes: @@ -65,7 +68,7 @@ - title: "Save to disk: Fix {pubdate} format string in template being ignored" tickets: [4140] - - title: Replace rotating hourglass with a more efficient bust indicator + - title: "Replace rotating hourglass with a more efficient busy indicator." - title: "PML Input: Make footnotes and sidebars display better" @@ -78,6 +81,9 @@ - title: "Fix PocketBook 360 driver on windows when no SD card is inserted" tickets: [4182] + - title: "Fix stopping of a recipe download would prevent it from being re-downloaded until a calibre restart" + tickets: [4007, 4158] + new recipes: - title: Rzeczpospolita OnLine diff --git a/src/calibre/devices/libusb1.py b/src/calibre/devices/libusb1.py index 63312c284e..bc90eaa9ec 100644 --- a/src/calibre/devices/libusb1.py +++ b/src/calibre/devices/libusb1.py @@ -9,7 +9,7 @@ __docformat__ = 'restructuredtext en' from calibre.constants import plugins -libusb, libusb_err = plugins['libusb'] +libusb, libusb_err = plugins.get('libusb', (None, 'Wrong platform')) def scan(): if libusb_err: diff --git a/src/calibre/gui2/dialogs/scheduler.py b/src/calibre/gui2/dialogs/scheduler.py index 4e28ab870d..8502fd7434 100644 --- a/src/calibre/gui2/dialogs/scheduler.py +++ b/src/calibre/gui2/dialogs/scheduler.py @@ -287,6 +287,14 @@ class Scheduler(QObject): finally: self.lock.unlock() + def recipe_download_failed(self, arg): + self.lock.lock() + try: + self.download_queue.remove(arg['urn']) + finally: + self.lock.unlock() + + def download_clicked(self, urn): if urn is not None: return self.download(urn) diff --git a/src/calibre/gui2/ui.py b/src/calibre/gui2/ui.py index ae6966bce4..d8ab5fb7a1 100644 --- a/src/calibre/gui2/ui.py +++ b/src/calibre/gui2/ui.py @@ -1224,6 +1224,7 @@ class Main(MainWindow, Ui_MainWindow, DeviceGUI): temp_files, fmt, arg = self.conversion_jobs.pop(job) pt = temp_files[0] if job.failed: + self.scheduler.recipe_download_failed(arg) return self.job_exception(job) id = self.library_view.model().add_news(pt.name, arg) self.library_view.model().reset()