This is an automated email from the ASF dual-hosted git repository. taragolis pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/main by this push: new dbdf743589 Resolve `RemovedIn20Warning` in `airflow task` command (#39244) dbdf743589 is described below commit dbdf7435893a709ed6044126983e7bcfe14aaa77 Author: Sebastian Daum <dau...@mediamarktsaturn.com> AuthorDate: Sat May 4 20:39:44 2024 +0200 Resolve `RemovedIn20Warning` in `airflow task` command (#39244) --- airflow/cli/commands/task_command.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/airflow/cli/commands/task_command.py b/airflow/cli/commands/task_command.py index 639ab74b8d..7cde8f478e 100644 --- a/airflow/cli/commands/task_command.py +++ b/airflow/cli/commands/task_command.py @@ -199,6 +199,8 @@ def _get_ti_db_access( ) # TODO: Validate map_index is in range? ti = TaskInstance(task, run_id=dag_run.run_id, map_index=map_index) + if dag_run in session: + session.add(ti) ti.dag_run = dag_run else: ti = ti_or_none