Fix off-by-one error with retries

Fixes #16408
This commit is contained in:
James Cammarata 2016-06-23 18:07:11 -05:00
parent 3e4755f7e4
commit 948682dbe2

View file

@ -423,9 +423,11 @@ class TaskExecutor:
# Read some values from the task, so that we can modify them if need be # Read some values from the task, so that we can modify them if need be
if self._task.until: if self._task.until:
retries = self._task.retries retries = self._task.retries + 1
if retries is None: if retries is None:
retries = 3 retries = 3
elif retries <= 0:
retries = 1
else: else:
retries = 1 retries = 1