hterik commented on issue #34723:
URL: https://github.com/apache/airflow/issues/34723#issuecomment-1748051842

   I've done some debugging:
   
   **Problem 1.** 
   Dag list is linking to the legacy `/graph` endpoint. This endpoint is only 
for backwards compatibility purposes and redirects to the new `/grid` endpoint. 
   This old function does actually calculate the `base_date` based on `run_id`, 
inside `dt_nr_dr_data = get_date_time_num_runs_dag_runs_form_data(request, 
session, dag)`
   
https://github.com/apache/airflow/blob/0c8e30e43b70e9d033e1686b327eb00aab82479c/airflow/www/views.py#L216-230
   But then it forgets to forward the `dt_nr_dr_data["base_date"]` in the 
returned kwargs: 
   
https://github.com/apache/airflow/blob/0c8e30e43b70e9d033e1686b327eb00aab82479c/airflow/www/views.py#L2964-2969
   SolutionA: Forward base_date 
   SolutionB: Change dag list to use new url
   
   **Problem 2**
   The new grid endpoint, receives the `run_id` parameter correctly, after the 
redirection described above.
   However, it then performs a Javascript fetch call to the `grid_data` API. In 
this API call, the `run_id` is NOT included.
   The `grid_data` function that serves this request has not implemented 
handling of run_id parameter, in the same way that the old 
`get_date_time_num_runs_dag_runs_form_data` function did.
   
https://github.com/apache/airflow/blob/0c8e30e43b70e9d033e1686b327eb00aab82479c/airflow/www/views.py#L3475-3478
   Solution C: Implement run_id handling in grid_data and forward the parameter 
from the frontend.
   
   
   I think both solution A and C are must haves here. B is optional, more nice 
to have to get rid of legacy in the future.


-- 
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: commits-unsubscr...@airflow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to