diff --git a/ee/tasks/subscriptions/__init__.py b/ee/tasks/subscriptions/__init__.py index 70f9b474d2a5b..443e5eb369995 100644 --- a/ee/tasks/subscriptions/__init__.py +++ b/ee/tasks/subscriptions/__init__.py @@ -1,7 +1,6 @@ from datetime import datetime, timedelta from typing import Optional -from django.conf import settings import structlog from prometheus_client import Counter from sentry_sdk import capture_exception, capture_message @@ -149,14 +148,12 @@ def schedule_all_subscriptions() -> None: report_timeout_seconds = settings.PARALLEL_ASSET_GENERATION_MAX_TIMEOUT_MINUTES * 60 * 1.5 -@app.task(soft_time_limit=report_timeout_seconds, timeout=report_timeout_seconds + 10) +@app.task(soft_time_limit=report_timeout_seconds, time_limit=report_timeout_seconds + 10) def deliver_subscription_report(subscription_id: int) -> None: - if not settings.TEST: - return return _deliver_subscription_report(subscription_id) -@app.task(soft_time_limit=30, time_limit=40) +@app.task(soft_time_limit=report_timeout_seconds, time_limit=report_timeout_seconds + 10) def handle_subscription_value_change( subscription_id: int, previous_value: str, invite_message: Optional[str] = None ) -> None: