|
|
8e1ca3 |
From 2003eb6b3d4a27a5de5eaa79418f115dd99886cd Mon Sep 17 00:00:00 2001
|
|
|
8e1ca3 |
From: Florence Blanc-Renaud <flo@redhat.com>
|
|
|
8e1ca3 |
Date: Sun, 7 Aug 2022 12:44:47 +0200
|
|
|
8e1ca3 |
Subject: [PATCH] check_repl_update: in progress is a boolean
|
|
|
8e1ca3 |
|
|
|
8e1ca3 |
With the fix for https://pagure.io/freeipa/issue/9171,
|
|
|
8e1ca3 |
nsds5replicaUpdateInProgress is now handled as a boolean.
|
|
|
8e1ca3 |
One remaining occurrence was still handling it as a string
|
|
|
8e1ca3 |
and calling lower() on its value.
|
|
|
8e1ca3 |
|
|
|
8e1ca3 |
Replace with direct boolean comparison.
|
|
|
8e1ca3 |
|
|
|
8e1ca3 |
Fixes: https://pagure.io/freeipa/issue/9218
|
|
|
8e1ca3 |
Signed-off-by: Florence Blanc-Renaud <flo@redhat.com>
|
|
|
8e1ca3 |
Reviewed-By: Alexander Bokovoy <abokovoy@redhat.com>
|
|
|
8e1ca3 |
---
|
|
|
8e1ca3 |
ipaserver/install/replication.py | 2 +-
|
|
|
8e1ca3 |
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
8e1ca3 |
|
|
|
8e1ca3 |
diff --git a/ipaserver/install/replication.py b/ipaserver/install/replication.py
|
|
|
8e1ca3 |
index 16be3760cb14bfeb1cc9a761400752071639dc7c..9d9aa1c4bfc99109c0cf1e6d1619ec1b38e20c02 100644
|
|
|
8e1ca3 |
--- a/ipaserver/install/replication.py
|
|
|
8e1ca3 |
+++ b/ipaserver/install/replication.py
|
|
|
8e1ca3 |
@@ -1152,7 +1152,7 @@ class ReplicationManager:
|
|
|
8e1ca3 |
except (ValueError, TypeError, KeyError):
|
|
|
8e1ca3 |
end = 0
|
|
|
8e1ca3 |
# incremental update is done if inprogress is false and end >= start
|
|
|
8e1ca3 |
- done = inprogress and inprogress.lower() == 'false' and start <= end
|
|
|
8e1ca3 |
+ done = inprogress is not None and not inprogress and start <= end
|
|
|
8e1ca3 |
logger.info("Replication Update in progress: %s: status: %s: "
|
|
|
8e1ca3 |
"start: %d: end: %d",
|
|
|
8e1ca3 |
inprogress, status, start, end)
|
|
|
8e1ca3 |
--
|
|
|
8e1ca3 |
2.37.2
|
|
|
8e1ca3 |
|