diff --git a/src/charm.py b/src/charm.py index aea8882ae..ad90f93c6 100755 --- a/src/charm.py +++ b/src/charm.py @@ -762,6 +762,9 @@ def _handle_potential_cluster_crash_scenario(self) -> bool: self.peers.data[unit].get("member-state", "unknown") for unit in self.peers.units } + # Add state for this unit (self.peers.units does not include this unit) + all_states.add("offline") + total_cluster_node_count = self.total_cluster_node_count if ( all_states == {"offline"} and self.unit.is_leader()