From cbc422df36a9f09715b55a2482421dd573713858 Mon Sep 17 00:00:00 2001 From: Luciano Gervasoni Date: Thu, 16 Oct 2025 10:38:32 +0200 Subject: [PATCH] Notify status bot token --- app_urls/fetcher/src/notifier.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app_urls/fetcher/src/notifier.py b/app_urls/fetcher/src/notifier.py index 97c4f58..26a45af 100644 --- a/app_urls/fetcher/src/notifier.py +++ b/app_urls/fetcher/src/notifier.py @@ -83,7 +83,7 @@ def notify_telegram_warning(last_hours, channel="WARNING"): urls_data_status_dict["total"] = urls_data_status_dict.get("total", 0) + o.get("count") MINIMUM_URLS_THRESHOLD = 10 - MINIMUM_PROCESSED_URLS_RATIO = 0.5 + MINIMUM_PROCESSED_URLS_RATIO = 0.7 # Minimum amount of URLs if (urls_data_status_dict.get("total") < MINIMUM_URLS_THRESHOLD): @@ -108,7 +108,7 @@ def notify_telegram_warning(last_hours, channel="WARNING"): .annotate(count=Count('id_url')) \ .order_by('id_source__source') - MINIMUM_SOURCES = 2 + MINIMUM_SOURCES = 3 if (len(urls_data_source) < MINIMUM_SOURCES): message += "WARNING - Very few sources found URLs during the last {} hours".format(last_hours) message += "\nURLs per source:\n"