From 164ef2c86c973fa3e9b0b6ca2ee9789f8e780cea Mon Sep 17 00:00:00 2001 From: Meisterlala <6453306+Meisterlala@users.noreply.github.com> Date: Sat, 29 Nov 2025 00:15:42 +0100 Subject: [PATCH] start metrics before the first file --- main.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index 77f73bc..eb9e045 100644 --- a/main.py +++ b/main.py @@ -325,7 +325,6 @@ def main(): while not shutdown_event.is_set(): processed_file = process_new() - ensure_metrics_server_started() if processed_file: # Update Jellyfin if JELLYFIN_API != "": @@ -380,7 +379,9 @@ def process_new() -> bool: total_files_skipped.set(len(skipped_files)) processed_count = len(all) - len(to_process) - len(skipped_files) total_files_transcoded.set(processed_count) + metrics_ready.set() + ensure_metrics_server_started() if len(to_process) >= 1 and not shutdown_event.is_set(): print(f"Found {len(to_process)} files to process.") -- knotmirror 0.0.1