bbovenzi commented on code in PR #34887:
URL: https://github.com/apache/airflow/pull/34887#discussion_r1496547257
##########
airflow/www/views.py:
##########
@@ -3465,25 +3466,42 @@ def grid_data(self):
if num_runs is None:
num_runs = conf.getint("webserver",
"default_dag_run_display_number")
- try:
- base_date = timezone.parse(request.args["base_date"], strict=True)
- except (KeyError, ValueError):
- base_date = dag.get_latest_execution_date() or timezone.utcnow()
+ dagrun = None
+ if run_id:
+ with create_session() as session:
+ dagrun = dag.get_dagrun(run_id=run_id, session=session)
+ if not dagrun:
+ return {"error": f"can't find dag_run_id={run_id}"}, 404
+ base_date = dagrun.execution_date
Review Comment:
I think this was specific to the widget so we're ok here.
--
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]