Repository: incubator-airflow Updated Branches: refs/heads/master 53ca50845 -> 35e43f506
[AIRFLOW-1050] Do not count up_for_retry as not ready up_for_retry tasks were incorrectly counted towards not_ready therefore marking a dag run deadlocked instead of retrying. Closes #2225 from bolkedebruin/AIRFLOW-1050 Project: http://git-wip-us.apache.org/repos/asf/incubator-airflow/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-airflow/commit/35e43f50 Tree: http://git-wip-us.apache.org/repos/asf/incubator-airflow/tree/35e43f50 Diff: http://git-wip-us.apache.org/repos/asf/incubator-airflow/diff/35e43f50 Branch: refs/heads/master Commit: 35e43f5067f4741640278b765c0e54e4fd45ffa3 Parents: 53ca508 Author: Bolke de Bruin <[email protected]> Authored: Fri Apr 7 08:00:10 2017 +0200 Committer: Bolke de Bruin <[email protected]> Committed: Fri Apr 7 08:00:10 2017 +0200 ---------------------------------------------------------------------- airflow/jobs.py | 9 +++++++++ 1 file changed, 9 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-airflow/blob/35e43f50/airflow/jobs.py ---------------------------------------------------------------------- diff --git a/airflow/jobs.py b/airflow/jobs.py index 0d4ae7f..f031f6e 100644 --- a/airflow/jobs.py +++ b/airflow/jobs.py @@ -1925,6 +1925,15 @@ class BackfillJob(BaseJob): started.pop(key) continue + # special case + if ti.state == State.UP_FOR_RETRY: + self.logger.debug("Task instance {} retry period not expired yet" + .format(ti)) + if key in started: + started.pop(key) + tasks_to_run[key] = ti + continue + # all remaining tasks self.logger.debug('Adding {} to not_ready'.format(ti)) not_ready.add(key)
