mirror of
https://github.com/outbackdingo/patroni.git
synced 2026-08-25 14:53:37 +00:00
scheduled_at needs a value for manual_failover (#1024)
The variable scheduled_at may be undefined for a manual failover where there is an exception raised trying to switchover with REST API.
This commit is contained in:
committed by
Alexander Kukushkin
parent
6909ce0c7a
commit
d418a9449e
@@ -625,6 +625,7 @@ def _do_failover_or_switchover(obj, action, cluster_name, master, candidate, for
|
||||
raise PatroniCtlException('Member {0} does not exist in cluster {1}'.format(candidate, cluster_name))
|
||||
|
||||
scheduled_at_str = None
|
||||
scheduled_at = None
|
||||
|
||||
if action == 'switchover':
|
||||
if scheduled is None and not force:
|
||||
|
||||
Reference in New Issue
Block a user