From 477615593e0e1c291df7f58422ecac8d4a73946d Mon Sep 17 00:00:00 2001 From: Broque Thomas Date: Thu, 26 Feb 2026 08:28:08 -0800 Subject: [PATCH] Increase Jellyfin API timeout default to 120 Raise the default Jellyfin API timeout for bulk operations from 30s to 120s to better handle slow servers and large database syncs. Updated core/jellyfin_client.py to set bulk_timeout to 120, webui/index.html to show 120s in the settings input, and webui/static/script.js to use 120 as the fallback when loading settings. Aligns UI and client behavior to reduce timeout errors during heavy syncs. --- core/jellyfin_client.py | 2 +- webui/index.html | 4 ++-- webui/static/script.js | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/core/jellyfin_client.py b/core/jellyfin_client.py index bdf0cce4..9defd2f3 100644 --- a/core/jellyfin_client.py +++ b/core/jellyfin_client.py @@ -454,7 +454,7 @@ class JellyfinClient: # Use configurable timeout for bulk operations (lots of data) is_bulk_operation = params and params.get('Limit', 0) > 1000 config = config_manager.get_jellyfin_config() - bulk_timeout = int(config.get('api_timeout', 30)) + bulk_timeout = int(config.get('api_timeout', 120)) timeout = bulk_timeout if is_bulk_operation else max(5, bulk_timeout // 6) try: diff --git a/webui/index.html b/webui/index.html index 1c5a014b..3f2b1624 100644 --- a/webui/index.html +++ b/webui/index.html @@ -2947,8 +2947,8 @@
- + Timeout for bulk API requests during database sync (15-300s). Increase if your Jellyfin server is slow to respond. diff --git a/webui/static/script.js b/webui/static/script.js index 975c411f..8a1d32c6 100644 --- a/webui/static/script.js +++ b/webui/static/script.js @@ -1787,7 +1787,7 @@ async function loadSettingsData() { // Populate Jellyfin settings document.getElementById('jellyfin-url').value = settings.jellyfin?.base_url || ''; document.getElementById('jellyfin-api-key').value = settings.jellyfin?.api_key || ''; - document.getElementById('jellyfin-timeout').value = settings.jellyfin?.api_timeout || 30; + document.getElementById('jellyfin-timeout').value = settings.jellyfin?.api_timeout || 120; // Populate Navidrome settings document.getElementById('navidrome-url').value = settings.navidrome?.base_url || '';