diff --git a/cps/tasks/thumbnail.py b/cps/tasks/thumbnail.py index cc847274..a7658c02 100644 --- a/cps/tasks/thumbnail.py +++ b/cps/tasks/thumbnail.py @@ -197,9 +197,11 @@ class TaskGenerateCoverThumbnails(CalibreTask): img.format = thumbnail.format img.save(filename=filename) else: - with open(filename, 'rb') as fd: + stream.seek(0) + with open(filename, 'wb') as fd: copyfileobj(stream, fd) + except Exception as ex: # Bubble exception to calling function self.log.debug('Error generating thumbnail file: ' + str(ex)) diff --git a/test/Calibre-Web TestSummary_Linux.html b/test/Calibre-Web TestSummary_Linux.html index ed5f5134..145bf9a7 100644 --- a/test/Calibre-Web TestSummary_Linux.html +++ b/test/Calibre-Web TestSummary_Linux.html @@ -37,14 +37,14 @@
Start Time: 2024-08-15 19:27:26
+Start Time: 2024-08-16 21:16:11
Stop Time: 2024-08-16 02:42:05
+Stop Time: 2024-08-17 04:31:06
Traceback (most recent call last): File "/home/ozzie/Development/calibre-web-test/test/test_ebook_convert_gdrive.py", line 495, in test_thumbnail_cache - self.assertEqual(count_files(thumbnail_cache_path), 20) -AssertionError: 25 != 20+ self.assertEqual(count_files(thumbnail_cache_path), 30) +AssertionError: 25 != 30
ImportError: Failed to import test module: test_ebook_convert_kepubify -Traceback (most recent call last): - File "/usr/lib/python3.10/unittest/loader.py", line 436, in _find_test_path - module = self._get_module_from_name(name) - File "/usr/lib/python3.10/unittest/loader.py", line 377, in _get_module_from_name - __import__(name) - File "/home/ozzie/Development/calibre-web-test/test/test_ebook_convert_kepubify.py", line 10, in <module> - from StringIO import StringIO -ModuleNotFoundError: No module named 'StringIO'-
ImportError: Failed to import test module: test_pip_install -Traceback (most recent call last): - File "/usr/lib/python3.10/unittest/loader.py", line 436, in _find_test_path - module = self._get_module_from_name(name) - File "/usr/lib/python3.10/unittest/loader.py", line 377, in _get_module_from_name - __import__(name) - File "/home/ozzie/Development/calibre-web-test/test/test_pip_install.py", line 14, in <module> - from build_release import make_release -ModuleNotFoundError: No module named 'build_release'-
Traceback (most recent call last): + File "/home/ozzie/Development/calibre-web-test/test/test_edit_additional_books.py", line 765, in test_delete_role + submit.click() + File "/home/ozzie/Development/calibre-web-test/venv/lib/python3.10/site-packages/selenium/webdriver/remote/webelement.py", line 93, in click + self._execute(Command.CLICK_ELEMENT) + File "/home/ozzie/Development/calibre-web-test/venv/lib/python3.10/site-packages/selenium/webdriver/remote/webelement.py", line 403, in _execute + return self._parent.execute(command, params) + File "/home/ozzie/Development/calibre-web-test/venv/lib/python3.10/site-packages/selenium/webdriver/remote/webdriver.py", line 440, in execute + self.error_handler.check_response(response) + File "/home/ozzie/Development/calibre-web-test/venv/lib/python3.10/site-packages/selenium/webdriver/remote/errorhandler.py", line 245, in check_response + raise exception_class(message, screen, stacktrace) +selenium.common.exceptions.ElementClickInterceptedException: Message: Element <button id="submit" class="btn btn-default" type="submit"> is not clickable at point (688,665) because another element <div class="modal-backdrop fade in"> obscures it +Stacktrace: +RemoteError@chrome://remote/content/shared/RemoteError.sys.mjs:8:8 +WebDriverError@chrome://remote/content/shared/webdriver/Errors.sys.mjs:193:5 +ElementClickInterceptedError@chrome://remote/content/shared/webdriver/Errors.sys.mjs:337:5 +webdriverClickElement@chrome://remote/content/marionette/interaction.sys.mjs:177:11 +interaction.clickElement@chrome://remote/content/marionette/interaction.sys.mjs:136:11 +clickElement@chrome://remote/content/marionette/actors/MarionetteCommandsChild.sys.mjs:205:29 +receiveMessage@chrome://remote/content/marionette/actors/MarionetteCommandsChild.sys.mjs:85:31+
Traceback (most recent call last): + File "/home/ozzie/Development/calibre-web-test/test/test_edit_additional_books.py", line 918, in test_details_popup + books[1][0]['ele'].click() +IndexError: list index out of range+
Traceback (most recent call last): + File "/home/ozzie/Development/calibre-web-test/test/test_edit_books_author_gdrive.py", line 608, in test_rename_capital_on_upload + self.assertEqual(['Frodo Beutlin', 'Norbert Halagal', 'Liu Yang', 'Hector Gonçalves'], details['author']) +AssertionError: Lists differ: ['Frodo Beutlin', 'Norbert Halagal', 'Liu Yang', 'Hector Gonçalves'] != [] + +First list contains 4 additional elements. +First extra element 0: +'Frodo Beutlin' + +- ['Frodo Beutlin', 'Norbert Halagal', 'Liu Yang', 'Hector Gonçalves'] ++ []+
Traceback (most recent call last): - File "/home/ozzie/Development/calibre-web-test/test/test_kobo_sync_big.py", line 482, in test_download_cover - self.assertEqual(count_files(thumbnail_cache_path), (BOOK_COUNT+10)*2) -AssertionError: 4590 != 3060-
ImportError: Failed to import test module: test_pip_install +Traceback (most recent call last): + File "/usr/lib/python3.10/unittest/loader.py", line 436, in _find_test_path + module = self._get_module_from_name(name) + File "/usr/lib/python3.10/unittest/loader.py", line 377, in _get_module_from_name + __import__(name) + File "/home/ozzie/Development/calibre-web-test/test/test_pip_install.py", line 23, in <module> + from build_release import make_release +ModuleNotFoundError: No module named 'build_release'+