You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by bb...@apache.org on 2026/04/15 14:15:39 UTC

(airflow) branch v3-2-test updated: fix(ui): invalidate task instances list query after clearing task instance (#63923) (#65304)

This is an automated email from the ASF dual-hosted git repository.

bbovenzi pushed a commit to branch v3-2-test
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/v3-2-test by this push:
     new 28a8ef55cf8 fix(ui): invalidate task instances list query after clearing task instance (#63923) (#65304)
28a8ef55cf8 is described below

commit 28a8ef55cf8f8c3590961d4c233f53ad7791ddeb
Author: Rahul Vats <43...@users.noreply.github.com>
AuthorDate: Wed Apr 15 19:45:30 2026 +0530

    fix(ui): invalidate task instances list query after clearing task instance (#63923) (#65304)
    
    After clearing a task instance, the TaskInstances list page was not
    refreshing to show the updated state. This was because `useClearTaskInstances`
    was missing `[useTaskInstanceServiceGetTaskInstancesKey]` in the list of
    query keys to invalidate on success.
    
    Both `useClearRun` and `usePatchTaskInstance` correctly invalidate this
    query — this change brings `useClearTaskInstances` in line with them.
    
    Fixes: #60703
    (cherry picked from commit f47038e9efb4aa1a193314b2df4c5f0c652be9d9)
    
    Co-authored-by: nagasrisai <59...@users.noreply.github.com>
---
 airflow-core/src/airflow/ui/src/queries/useClearTaskInstances.ts | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/airflow-core/src/airflow/ui/src/queries/useClearTaskInstances.ts b/airflow-core/src/airflow/ui/src/queries/useClearTaskInstances.ts
index b02cc1bbac6..2d70c49bc5b 100644
--- a/airflow-core/src/airflow/ui/src/queries/useClearTaskInstances.ts
+++ b/airflow-core/src/airflow/ui/src/queries/useClearTaskInstances.ts
@@ -24,6 +24,7 @@ import {
   useDagRunServiceGetDagRunsKey,
   UseGanttServiceGetGanttDataKeyFn,
   UseTaskInstanceServiceGetMappedTaskInstanceKeyFn,
+  useTaskInstanceServiceGetTaskInstancesKey,
   useTaskInstanceServicePostClearTaskInstances,
 } from "openapi/queries";
 import type { ApiError } from "openapi/requests";
@@ -114,6 +115,7 @@ export const useClearTaskInstances = ({
       ...taskInstanceKeys,
       UseDagRunServiceGetDagRunKeyFn({ dagId, dagRunId }),
       [useDagRunServiceGetDagRunsKey],
+      [useTaskInstanceServiceGetTaskInstancesKey],
       [useClearTaskInstancesDryRunKey, dagId],
       [usePatchTaskInstanceDryRunKey, dagId, dagRunId],
       UseGanttServiceGetGanttDataKeyFn({ dagId, runId: dagRunId }),