Don't let max_fail_percentage affect future plays.

This commit is contained in:
Vincent Roy 2016-04-14 14:45:57 -03:00 committed by James Cammarata
parent 46e9e4c4da
commit 5e9b13cb94

View file

@ -367,7 +367,7 @@ class StrategyModule(StrategyBase):
if iterator._play.max_fail_percentage is not None and len(results) > 0: if iterator._play.max_fail_percentage is not None and len(results) > 0:
percentage = iterator._play.max_fail_percentage / 100.0 percentage = iterator._play.max_fail_percentage / 100.0
if (len(failed_hosts) / len(results)) > percentage: if (len(iterator.get_failed_hosts()) / len(results)) > percentage:
for host in hosts_left: for host in hosts_left:
# don't double-mark hosts, or the iterator will potentially # don't double-mark hosts, or the iterator will potentially
# fail them out of the rescue/always states # fail them out of the rescue/always states