vardancse commented on a change in pull request #4781: [AIRFLOW-3962] Added
graceful handling for creation of dag_run of a dag which doesn't have any task
URL: https://github.com/apache/airflow/pull/4781#discussion_r283082809
##########
File path: airflow/jobs.py
##########
@@ -865,8 +865,8 @@ def create_dag_run(self, dag, session=None):
dag.start_date, next_run_date
)
- # don't ever schedule in the future
- if next_run_date > timezone.utcnow():
+ # don't ever schedule in the future or if next_run_date is None
+ if not next_run_date or next_run_date > timezone.utcnow():
Review comment:
@tooptoop4 AFAIK external triggered request never comes to this route, this
is used for creation of scheduled dag_run. Fix was around graceful handling of
date time exception, more details available here
https://issues.apache.org/jira/browse/AIRFLOW-3962
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services