From a76639e5b315b3d0a787260b166c598289a939b0 Mon Sep 17 00:00:00 2001 From: Filip Balak Date: Mon, 27 Nov 2023 09:35:46 +0100 Subject: [PATCH] refresh with any error (#8915) Signed-off-by: fbalak --- ocs_ci/utility/prometheus.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ocs_ci/utility/prometheus.py b/ocs_ci/utility/prometheus.py index 91436a22c9a..bd5c012eed0 100644 --- a/ocs_ci/utility/prometheus.py +++ b/ocs_ci/utility/prometheus.py @@ -443,7 +443,7 @@ def get(self, resource, payload=None, timeout=300): }, ): response = sample_response - if response.status_code == 503: + if not response.ok: logger.warning(f"There was an error in response: {response.text}") logger.warning("Refreshing connection") self.refresh_connection()