mirror of
https://github.com/denizsafak/abogen.git
synced 2026-07-18 05:40:26 +02:00
feat: Update Audiobookshelf timeout settings to 3600 seconds for improved upload reliability
This commit is contained in:
@@ -30,7 +30,7 @@ class AudiobookshelfConfig:
|
|||||||
send_cover: bool = True
|
send_cover: bool = True
|
||||||
send_chapters: bool = True
|
send_chapters: bool = True
|
||||||
send_subtitles: bool = True
|
send_subtitles: bool = True
|
||||||
timeout: float = 30.0
|
timeout: float = 3600.0
|
||||||
|
|
||||||
def normalized_base_url(self) -> str:
|
def normalized_base_url(self) -> str:
|
||||||
base = (self.base_url or "").strip()
|
base = (self.base_url or "").strip()
|
||||||
|
|||||||
@@ -2559,9 +2559,9 @@ def _build_audiobookshelf_config(settings: Mapping[str, Any]) -> Optional[Audiob
|
|||||||
if not (base_url and api_token and library_id):
|
if not (base_url and api_token and library_id):
|
||||||
return None
|
return None
|
||||||
try:
|
try:
|
||||||
timeout = float(settings.get("timeout", 30.0))
|
timeout = float(settings.get("timeout", 3600.0))
|
||||||
except (TypeError, ValueError):
|
except (TypeError, ValueError):
|
||||||
timeout = 30.0
|
timeout = 3600.0
|
||||||
return AudiobookshelfConfig(
|
return AudiobookshelfConfig(
|
||||||
base_url=base_url,
|
base_url=base_url,
|
||||||
api_token=api_token,
|
api_token=api_token,
|
||||||
|
|||||||
@@ -1054,11 +1054,11 @@ class ConversionService:
|
|||||||
job.add_log("Audiobookshelf upload skipped: audio output not found.", level="warning")
|
job.add_log("Audiobookshelf upload skipped: audio output not found.", level="warning")
|
||||||
return
|
return
|
||||||
|
|
||||||
timeout_raw = integration_cfg.get("timeout", 30.0)
|
timeout_raw = integration_cfg.get("timeout", 3600.0)
|
||||||
try:
|
try:
|
||||||
timeout_value = float(timeout_raw)
|
timeout_value = float(timeout_raw)
|
||||||
except (TypeError, ValueError):
|
except (TypeError, ValueError):
|
||||||
timeout_value = 30.0
|
timeout_value = 3600.0
|
||||||
|
|
||||||
config = AudiobookshelfConfig(
|
config = AudiobookshelfConfig(
|
||||||
base_url=base_url,
|
base_url=base_url,
|
||||||
|
|||||||
Reference in New Issue
Block a user