vatsrahul1001 commented on code in PR #46390:
URL: https://github.com/apache/airflow/pull/46390#discussion_r1948704995
##########
airflow/api_fastapi/core_api/datamodels/dag_run.py:
##########
@@ -96,18 +96,16 @@ def check_data_intervals(cls, values):
)
return values
+ ## when logical date is null, the run id should be generated from
run_after + random string.
+ # TODO we need to modify this validator after
https://github.com/apache/airflow/pull/46398 is merged
Review Comment:
Implemented
##########
airflow/api_fastapi/core_api/routes/public/dag_run.py:
##########
@@ -354,7 +356,8 @@ def trigger_dag_run(
f"DAG with dag_id: '{dag_id}' has import errors and cannot be
triggered",
)
- logical_date = pendulum.instance(body.logical_date)
+ logical_date = pendulum.instance(body.logical_date) if body.logical_date
is not None else None
Review Comment:
Implemented
##########
airflow/models/dag.py:
##########
@@ -1781,7 +1781,8 @@ def create_dagrun(
:meta private:
"""
- logical_date = timezone.coerce_datetime(logical_date)
+ if logical_date is not None:
+ logical_date = timezone.coerce_datetime(logical_date)
Review Comment:
Implemented
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]