diff --git a/backend/src/module/network/request_contents.py b/backend/src/module/network/request_contents.py index a2c7ebff..0ea39d4a 100644 --- a/backend/src/module/network/request_contents.py +++ b/backend/src/module/network/request_contents.py @@ -41,7 +41,11 @@ class RequestContent(RequestURL): async def get_xml(self, _url, retry: int = 3) -> xml.etree.ElementTree.Element: req = await self.get_url(_url, retry) if req: - return xml.etree.ElementTree.fromstring(req.text) + try: + return xml.etree.ElementTree.fromstring(req.text) + except xml.etree.ElementTree.ParseError as e: + logger.warning(f"[Network] Failed to parse XML from {_url}: {e}") + return None # API JSON async def get_json(self, _url) -> dict: diff --git a/backend/src/module/network/request_url.py b/backend/src/module/network/request_url.py index 6285c34a..2c72ffd5 100644 --- a/backend/src/module/network/request_url.py +++ b/backend/src/module/network/request_url.py @@ -62,7 +62,7 @@ class RequestURL: base_headers = { "User-Agent": self.DEFAULT_UA, "Accept-Language": "en-US,en;q=0.9", - "Accept-Encoding": "gzip, deflate, br", + "Accept-Encoding": "gzip, deflate", "Connection": "keep-alive", } # For torrent files, use different Accept header diff --git a/webui/src/App.vue b/webui/src/App.vue index 21e28b3a..91dd422e 100644 --- a/webui/src/App.vue +++ b/webui/src/App.vue @@ -1,6 +1,6 @@ @@ -56,8 +100,8 @@ function handleConfirm() {
-