Lee-W commented on code in PR #54416:
URL: https://github.com/apache/airflow/pull/54416#discussion_r2318283676


##########
airflow-core/src/airflow/api_fastapi/core_api/routes/public/task_instances.py:
##########
@@ -713,10 +713,10 @@ def post_clear_task_instances(
             raise HTTPException(status.HTTP_404_NOT_FOUND, error_message)
         # Get the specific dag version:
         dag = get_dag_for_run(dag_bag, dag_run, session)
-        if past or future:
+        if (past or future) and dag_run.logical_date is None:
             raise HTTPException(
                 status.HTTP_400_BAD_REQUEST,
-                "Cannot use include_past or include_future when dag_run_id is 
provided because logical_date is not applicable.",
+                "Cannot use include_past or include_future with a manually 
triggered DAG run (logical_date is None).",

Review Comment:
   ```suggestion
                   "Cannot use include_past or include_future with a manually 
triggered Dag run (logical_date is None).",
   ```
   
   an asset triggered Dag will also have `logical_date` is none. the 
description here is inaccurate



-- 
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]

Reply via email to