diff --git a/cps/admin.py b/cps/admin.py index 6252b317..6076e86d 100644 --- a/cps/admin.py +++ b/cps/admin.py @@ -219,7 +219,7 @@ def admin(): form_date += timedelta(hours=int(commit[20:22]), minutes=int(commit[23:])) commit = format_datetime(form_date - tz, format='short') else: - commit = version.replace("b", " Beta") + commit = version['version'].replace("b", " Beta") all_user = ub.session.query(ub.User).all() # email_settings = mail_config.get_mail_settings() diff --git a/cps/static/js/caliBlur.js b/cps/static/js/caliBlur.js old mode 100755 new mode 100644 diff --git a/cps/tasks/convert.py b/cps/tasks/convert.py old mode 100755 new mode 100644 diff --git a/cps/templates/config_edit.html b/cps/templates/config_edit.html old mode 100755 new mode 100644 diff --git a/cps/updater.py b/cps/updater.py index ab67e7a6..e33b80f4 100644 --- a/cps/updater.py +++ b/cps/updater.py @@ -329,7 +329,7 @@ class Updater(threading.Thread): @classmethod def _stable_version_info(cls): log.debug("Stable version: {}".format(constants.STABLE_VERSION)) - return constants.STABLE_VERSION # Current Version + return {'version': constants.STABLE_VERSION } @classmethod def dry_run(cls): diff --git a/pyproject.toml b/pyproject.toml index 43221289..49f2d915 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -50,6 +50,7 @@ dependencies = [ "regex>=2022.3.2,<2024.6.25", "bleach>=6.0.0,<6.2.0", "python-magic>=0.4.27,<0.5.0", + "python-magic-bin>=0.4.0,<0.5.0;sys_platform=='win32'", "flask-httpAuth>=4.4.0,<5.0.0", "cryptography>=30.0.0,<44.0.0", ] diff --git a/test/Calibre-Web TestSummary_Linux.html b/test/Calibre-Web TestSummary_Linux.html index 629d9ce7..f7d5c054 100644 --- a/test/Calibre-Web TestSummary_Linux.html +++ b/test/Calibre-Web TestSummary_Linux.html @@ -37,20 +37,20 @@
Start Time: 2024-11-02 20:22:07
+Start Time: 2024-11-10 20:11:07
Stop Time: 2024-11-03 03:38:36
+Stop Time: 2024-11-11 03:26:27
Duration: 6h 9 min
+Duration: 6h 7 min
Traceback (most recent call last): - File "/home/ozzie/Development/calibre-web-test/test/test_login.py", line 347, in test_password_policy - self.create_user('lower_user', {'password': '123456P+', 'email': 'a3@b.com'}) - File "/home/ozzie/Development/calibre-web-test/test/helper_ui.py", line 1013, in create_user - return cls.change_user(config) - File "/home/ozzie/Development/calibre-web-test/test/helper_ui.py", line 1083, in change_user - ele = cls.driver.find_element(By.ID, key) - File "/home/ozzie/Development/calibre-web-test/venv/lib/python3.10/site-packages/selenium/webdriver/remote/webdriver.py", line 830, in find_element - return self.execute(Command.FIND_ELEMENT, {"using": by, "value": value})["value"] - 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.NoSuchElementException: Message: Unable to locate element: [id="password"] -Stacktrace: -RemoteError@chrome://remote/content/shared/RemoteError.sys.mjs:8:8 -WebDriverError@chrome://remote/content/shared/webdriver/Errors.sys.mjs:193:5 -NoSuchElementError@chrome://remote/content/shared/webdriver/Errors.sys.mjs:511:5 -dom.find/</<@chrome://remote/content/shared/DOM.sys.mjs:136:16-
Traceback (most recent call last): + File "/home/ozzie/Development/calibre-web-test/test/test_updater.py", line 153, in test_check_update_stable_errors + self.check_updater('Timeout', "alert", 13) + File "/home/ozzie/Development/calibre-web-test/test/test_updater.py", line 87, in check_updater + self.assertTrue(responsetext in self.check_element_on_page((By.ID, "message")).text) +AttributeError: 'bool' object has no attribute 'text'+
Traceback (most recent call last): + File "/home/ozzie/Development/calibre-web-test/test/test_updater.py", line 181, in test_check_update_stable_versions + self.check_updater('{}.{}.{}'.format(*version3), "alert-warning") + File "/home/ozzie/Development/calibre-web-test/test/test_updater.py", line 87, in check_updater + self.assertTrue(responsetext in self.check_element_on_page((By.ID, "message")).text) +AttributeError: 'bool' object has no attribute 'text'+
Traceback (most recent call last): + File "/home/ozzie/Development/calibre-web-test/test/test_updater.py", line 390, in test_perform_update + performUpdate.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.ElementNotInteractableException: Message: Element <div id="perform_update" class="btn btn-primary hidden"> could not be scrolled into view +Stacktrace: +RemoteError@chrome://remote/content/shared/RemoteError.sys.mjs:8:8 +WebDriverError@chrome://remote/content/shared/webdriver/Errors.sys.mjs:193:5 +ElementNotInteractableError@chrome://remote/content/shared/webdriver/Errors.sys.mjs:353:5 +webdriverClickElement@chrome://remote/content/marionette/interaction.sys.mjs:167: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_updater.py", line 330, in test_perform_update_stable_errors + performUpdate.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.ElementNotInteractableException: Message: Element <div id="perform_update" class="btn btn-primary hidden"> could not be scrolled into view +Stacktrace: +RemoteError@chrome://remote/content/shared/RemoteError.sys.mjs:8:8 +WebDriverError@chrome://remote/content/shared/webdriver/Errors.sys.mjs:193:5 +ElementNotInteractableError@chrome://remote/content/shared/webdriver/Errors.sys.mjs:353:5 +webdriverClickElement@chrome://remote/content/marionette/interaction.sys.mjs:167: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_updater.py", line 431, in test_update_write_protect + self.assertTrue(self.check_element_on_page((By.ID, "message"))) +AssertionError: False is not true+