From 82cd8e6d80a2afcd5e420aec046739961a2f5125 Mon Sep 17 00:00:00 2001 From: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> Date: Tue, 17 Feb 2026 16:15:38 +0000 Subject: [PATCH] fix: improve fallback behavior when using custom data system configuration Co-Authored-By: mkeeler@launchdarkly.com --- ldclient/impl/datasystem/fdv2.py | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/ldclient/impl/datasystem/fdv2.py b/ldclient/impl/datasystem/fdv2.py index 8c5b9c1e..97f207f3 100644 --- a/ldclient/impl/datasystem/fdv2.py +++ b/ldclient/impl/datasystem/fdv2.py @@ -656,20 +656,12 @@ def _recovery_condition(self, status: DataSourceStatus) -> bool: :param status: Current data source status :return: True if recovery condition is met """ - interrupted_at_runtime = ( - status.state == DataSourceState.INTERRUPTED - and time.time() - status.since > 60 # 1 minute - ) healthy_for_too_long = ( status.state == DataSourceState.VALID and time.time() - status.since > 300 # 5 minutes ) - cannot_initialize = ( - status.state == DataSourceState.INITIALIZING - and time.time() - status.since > 10 # 10 seconds - ) - return interrupted_at_runtime or healthy_for_too_long or cannot_initialize + return healthy_for_too_long def _persistent_store_outage_recovery(self, data_store_status: DataStoreStatus): """