This is an automated email from the ASF dual-hosted git repository.
bbovenzi 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 f6b9c0234aa Fix Gantt view still visible when time range is outside
dagrun window #64147 (#64179)
f6b9c0234aa is described below
commit f6b9c0234aab4583f642f068f6e538d8ba83f5ac
Author: Haseeb Malik <[email protected]>
AuthorDate: Tue Mar 31 15:02:58 2026 -0400
Fix Gantt view still visible when time range is outside dagrun window
#64147 (#64179)
---
airflow-core/src/airflow/ui/src/layouts/Details/DetailsLayout.tsx | 2 ++
airflow-core/src/airflow/ui/src/layouts/Details/Gantt/Gantt.tsx | 8 ++++++--
2 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/airflow-core/src/airflow/ui/src/layouts/Details/DetailsLayout.tsx
b/airflow-core/src/airflow/ui/src/layouts/Details/DetailsLayout.tsx
index 075f710b10f..dd559e0ac5e 100644
--- a/airflow-core/src/airflow/ui/src/layouts/Details/DetailsLayout.tsx
+++ b/airflow-core/src/airflow/ui/src/layouts/Details/DetailsLayout.tsx
@@ -201,6 +201,8 @@ export const DetailsLayout = ({ children, error, isLoading,
tabs }: Props) => {
<Gantt
dagRunState={dagRunStateFilter}
limit={limit}
+ runAfterGte={runAfterGte}
+ runAfterLte={runAfterLte}
runType={runTypeFilter}
triggeringUser={triggeringUserFilter}
/>
diff --git a/airflow-core/src/airflow/ui/src/layouts/Details/Gantt/Gantt.tsx
b/airflow-core/src/airflow/ui/src/layouts/Details/Gantt/Gantt.tsx
index 71d14ccfbe7..62de32cdb98 100644
--- a/airflow-core/src/airflow/ui/src/layouts/Details/Gantt/Gantt.tsx
+++ b/airflow-core/src/airflow/ui/src/layouts/Details/Gantt/Gantt.tsx
@@ -71,6 +71,8 @@ ChartJS.register(
type Props = {
readonly dagRunState?: DagRunState | undefined;
readonly limit: number;
+ readonly runAfterGte?: string | undefined;
+ readonly runAfterLte?: string | undefined;
readonly runType?: DagRunType | undefined;
readonly triggeringUser?: string | undefined;
};
@@ -79,7 +81,7 @@ const CHART_PADDING = 36;
const CHART_ROW_HEIGHT = 20;
const MIN_BAR_WIDTH = 10;
-export const Gantt = ({ dagRunState, limit, runType, triggeringUser }: Props)
=> {
+export const Gantt = ({ dagRunState, limit, runAfterGte, runAfterLte, runType,
triggeringUser }: Props) => {
const { dagId = "", groupId: selectedGroupId, runId = "", taskId:
selectedTaskId } = useParams();
const [searchParams] = useSearchParams();
const { openGroupIds } = useOpenGroups();
@@ -114,6 +116,8 @@ export const Gantt = ({ dagRunState, limit, runType,
triggeringUser }: Props) =>
const { data: gridRuns, isLoading: runsLoading } = useGridRuns({
dagRunState,
limit,
+ runAfterGte,
+ runAfterLte,
runType,
triggeringUser,
});
@@ -208,7 +212,7 @@ export const Gantt = ({ dagRunState, limit, runType,
triggeringUser }: Props) =>
translate,
});
- if (runId === "") {
+ if (runId === "" || (!isLoading && !selectedRun)) {
return undefined;
}