You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by ra...@apache.org on 2026/03/03 08:38:35 UTC
(airflow) branch backport-62510 updated (4845ed5eeac -> 830902228af)
This is an automated email from the ASF dual-hosted git repository.
rahulvats pushed a change to branch backport-62510
in repository https://gitbox.apache.org/repos/asf/airflow.git
discard 4845ed5eeac fix(ui): use ISO dates in Gantt chart for cross-browser consistency (#61250)
new 830902228af fix(ui): use ISO dates in Gantt chart for cross-browser consistency (#61250)
This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version. This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:
* -- * -- B -- O -- O -- O (4845ed5eeac)
\
N -- N -- N refs/heads/backport-62510 (830902228af)
You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.
Any revisions marked "omit" are not gone; other references still
refer to them. Any revisions marked "discard" are gone forever.
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
airflow-core/src/airflow/ui/src/layouts/Details/Gantt/Gantt.tsx | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
(airflow) 01/01: fix(ui): use ISO dates in Gantt chart for cross-browser consistency (#61250)
Posted by ra...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
rahulvats pushed a commit to branch backport-62510
in repository https://gitbox.apache.org/repos/asf/airflow.git
commit 830902228af71d28056da6d369199024ced02e22
Author: yuseok89 <yu...@gmail.com>
AuthorDate: Sat Jan 31 01:25:21 2026 +0900
fix(ui): use ISO dates in Gantt chart for cross-browser consistency (#61250)
(cherry picked from commit 705107621ca10fed635b0374ab1b9ca46b11766f)
---
.../src/airflow/ui/src/layouts/Details/Gantt/Gantt.tsx | 17 ++++++-----------
1 file changed, 6 insertions(+), 11 deletions(-)
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 54d2c476b41..7dec8f4354e 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
@@ -52,7 +52,6 @@ import { useGridStructure } from "src/queries/useGridStructure";
import { useGridTiSummaries } from "src/queries/useGridTISummaries";
import { getComputedCSSVariableValue } from "src/theme";
import { isStatePending, useAutoRefresh } from "src/utils";
-import { DEFAULT_DATETIME_FORMAT_WITH_TZ, formatDate } from "src/utils/datetimeUtils";
import { createHandleBarClick, createHandleBarHover, createChartOptions } from "./utils";
@@ -144,8 +143,6 @@ export const Gantt = ({ limit, runType, triggeringUser }: Props) => {
const isLoading = runsLoading || structureLoading || summariesLoading || tiLoading;
- const currentTime = dayjs().tz(selectedTimezone).format(DEFAULT_DATETIME_FORMAT_WITH_TZ);
-
const data = useMemo(() => {
if (isLoading || runId === "") {
return [];
@@ -159,15 +156,15 @@ export const Gantt = ({ limit, runType, triggeringUser }: Props) => {
const gridSummary = gridSummaries.find((ti) => ti.task_id === node.id);
if ((node.isGroup ?? node.is_mapped) && gridSummary) {
- // Use min/max times from grid summary
+ // Use min/max times from grid summary; ISO so time scale and bar positions render consistently across browsers
return {
isGroup: node.isGroup,
isMapped: node.is_mapped,
state: gridSummary.state,
taskId: gridSummary.task_id,
x: [
- formatDate(gridSummary.min_start_date, selectedTimezone, DEFAULT_DATETIME_FORMAT_WITH_TZ),
- formatDate(gridSummary.max_end_date, selectedTimezone, DEFAULT_DATETIME_FORMAT_WITH_TZ),
+ dayjs(gridSummary.min_start_date).toISOString(),
+ dayjs(gridSummary.max_end_date).toISOString(),
],
y: gridSummary.task_id,
};
@@ -177,17 +174,15 @@ export const Gantt = ({ limit, runType, triggeringUser }: Props) => {
if (taskInstance) {
const hasTaskRunning = isStatePending(taskInstance.state);
- const endTime = hasTaskRunning ? currentTime : taskInstance.end_date;
+ const endTime = hasTaskRunning ? dayjs().toISOString() : taskInstance.end_date;
+
return {
isGroup: node.isGroup,
isMapped: node.is_mapped,
state: taskInstance.state,
taskId: taskInstance.task_id,
- x: [
- formatDate(taskInstance.start_date, selectedTimezone, DEFAULT_DATETIME_FORMAT_WITH_TZ),
- formatDate(endTime, selectedTimezone, DEFAULT_DATETIME_FORMAT_WITH_TZ),
- ],
+ x: [dayjs(taskInstance.start_date).toISOString(), dayjs(endTime).toISOString()],
y: taskInstance.task_id,
};
}