Correcting conditionals looping (#43331) (#43346)

* Correcting conditionals looping (#43331)

Empty conditionals would not break out of the loop, causing every command to be run for the same number of times as retries is defined (10 by default)

(cherry picked from commit e215f842ba)

* Update changelog
pull/43364/head
Ganesh Nalawade 6 years ago committed by Matt Clay
parent 460183ce47
commit aee1d42fe7

@ -0,0 +1,2 @@
bugfixes:
- vyos_command correcting conditionals looping (https://github.com/ansible/ansible/pull/43331).

@ -212,10 +212,10 @@ def main():
break break
conditionals.remove(item) conditionals.remove(item)
if not conditionals: if not conditionals:
break break
time.sleep(interval) time.sleep(interval)
if conditionals: if conditionals:
failed_conditions = [item.raw for item in conditionals] failed_conditions = [item.raw for item in conditionals]

Loading…
Cancel
Save