We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5df41b8 commit 28c3f19Copy full SHA for 28c3f19
src/common/core/utils.py
@@ -130,6 +130,7 @@ def get_file_contents(file_path: str) -> str | None:
130
return None
131
132
133
+@lru_cache()
134
def is_database_replica_setup() -> bool:
135
"""Checks if any database replica is set up"""
136
return any(
tests/unit/common/core/test_utils.py
@@ -223,6 +223,7 @@ def test_is_database_replica_setup__tells_whether_any_replica_is_present(
223
mocker: MockerFixture,
224
) -> None:
225
# Given
226
+ is_database_replica_setup.cache_clear()
227
mocker.patch(
228
"common.core.utils.connections",
229
{name: connections["default"] for name in database_names},
0 commit comments