uranusjr commented on code in PR #32011:
URL: https://github.com/apache/airflow/pull/32011#discussion_r1236674971
##########
airflow/www/views.py:
##########
@@ -1419,7 +1419,11 @@ def rendered_templates(self, session):
ti.dag_run = DagRun(dag_id=dag_id, execution_date=dttm)
else:
ti = dag_run.get_task_instance(task_id=task_id,
map_index=map_index, session=session)
- ti.refresh_from_task(raw_task)
+ if ti:
+ ti.refresh_from_task(raw_task)
+ else:
+ # When there is no task instance with the given map_index
+ ti = TaskInstance(raw_task, map_index=map_index)
Review Comment:
Do we want to keep the _Rendered Template_ line in the empty tab? (That’s
`title` I think?) Maybe we can change it to a `Markup` object that shows some
details on the error.
--
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]