mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 12:50:22 -07:00
Take ITERATING_ALWAYS into account when setting failed state in PlayIterator
Fixes #15963
This commit is contained in:
parent
1975a545bd
commit
4dc2bf4815
2 changed files with 8 additions and 3 deletions
|
@ -70,9 +70,12 @@ class StrategyModule(StrategyBase):
|
|||
if state_task and state_task[1]]
|
||||
|
||||
if host_tasks_to_run:
|
||||
lowest_cur_block = min(
|
||||
(s.cur_block for h, (s, t) in host_tasks_to_run
|
||||
if s.run_state != PlayIterator.ITERATING_COMPLETE))
|
||||
try:
|
||||
lowest_cur_block = min(
|
||||
(s.cur_block for h, (s, t) in host_tasks_to_run
|
||||
if s.run_state != PlayIterator.ITERATING_COMPLETE))
|
||||
except ValueError:
|
||||
lowest_cur_block = None
|
||||
else:
|
||||
# empty host_tasks_to_run will just run till the end of the function
|
||||
# without ever touching lowest_cur_block
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue