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"