mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-24 19:31:26 -07:00
Fixing bugs in strategies
* Don't filter hosts remaining based on their failed state. Instead rely on the PlayIterator to return None/ITERATING_COMPLETE when the host is failed. * In the free strategy, make sure we wait outside the host loop for all pending results to be processed. * Use the internal _set_failed_state() instead of manually setting things when a failed child state is hit Fixes #15623
This commit is contained in:
parent
5c7ad654db
commit
09c90f7f2f
3 changed files with 10 additions and 8 deletions
|
@ -163,7 +163,7 @@ class StrategyModule(StrategyBase):
|
|||
|
||||
try:
|
||||
display.debug("getting the remaining hosts for this loop")
|
||||
hosts_left = [host for host in self._inventory.get_hosts(iterator._play.hosts) if host.name not in self._tqm._unreachable_hosts and not iterator.is_failed(host)]
|
||||
hosts_left = [host for host in self._inventory.get_hosts(iterator._play.hosts) if host.name not in self._tqm._unreachable_hosts]
|
||||
display.debug("done getting the remaining hosts for this loop")
|
||||
|
||||
# queue up this task for each host in the inventory
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue