From 1cc6a6c4ce93e8ce26705e92129d4bfbc2c174f3 Mon Sep 17 00:00:00 2001 From: nicholas Date: Wed, 1 Sep 2021 12:29:39 -0400 Subject: [PATCH 1/3] Failed flows card should use start_time timestamp instead of updated --- src/graphql/Dashboard/flow-failures.gql | 6 +++--- src/pages/Dashboard/FailedFlows-Tile.vue | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/graphql/Dashboard/flow-failures.gql b/src/graphql/Dashboard/flow-failures.gql index fd3262051..8774d7da0 100644 --- a/src/graphql/Dashboard/flow-failures.gql +++ b/src/graphql/Dashboard/flow-failures.gql @@ -4,10 +4,10 @@ query FlowFailures($projectId: uuid, $heartbeat: timestamptz, $tenantId: uuid) { tenant_id: { _eq: $tenantId } flow: { project_id: { _eq: $projectId } } state: { _eq: "Failed" } - updated: { _gte: $heartbeat } + start_time: { _gte: $heartbeat } } distinct_on: flow_id - order_by: { flow_id: asc, updated: desc } + order_by: { flow_id: asc, start_time: desc } ) { flow_id state_timestamp @@ -18,6 +18,6 @@ query FlowFailures($projectId: uuid, $heartbeat: timestamptz, $tenantId: uuid) { flow_group_id } - updated + start_time } } diff --git a/src/pages/Dashboard/FailedFlows-Tile.vue b/src/pages/Dashboard/FailedFlows-Tile.vue index a913d19fe..1ad98c710 100644 --- a/src/pages/Dashboard/FailedFlows-Tile.vue +++ b/src/pages/Dashboard/FailedFlows-Tile.vue @@ -123,7 +123,7 @@ export default { - Filter by when flows were last updated + Filter on flow run start time From 64e546f35ae6350516125db85c4f0184a5892cb2 Mon Sep 17 00:00:00 2001 From: nicholas Date: Wed, 1 Sep 2021 12:32:41 -0400 Subject: [PATCH 2/3] Update changelog --- Changelog.md | 1 + 1 file changed, 1 insertion(+) diff --git a/Changelog.md b/Changelog.md index 26e93d036..3b2c2a3cc 100644 --- a/Changelog.md +++ b/Changelog.md @@ -8,6 +8,7 @@ ### Bugfixes +- Filter dashboard failed flow tile on start_time instead of updated timestamp - [#1028](https://github.com/PrefectHQ/ui/pull/1028) - Stop role reset in the team member invite dialog - [#1019](https://github.com/PrefectHQ/ui/pull/1019) ## 2021-08-18 From 1313ae1a01fede70a060a1edf651fbd3dd13c60e Mon Sep 17 00:00:00 2001 From: nicholas Date: Wed, 1 Sep 2021 21:48:46 -0400 Subject: [PATCH 3/3] Use scheduled_start_time instead of start_time --- src/graphql/Dashboard/flow-failures.gql | 6 +++--- src/pages/Dashboard/FailedFlows-Tile.vue | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/graphql/Dashboard/flow-failures.gql b/src/graphql/Dashboard/flow-failures.gql index 8774d7da0..695e4db71 100644 --- a/src/graphql/Dashboard/flow-failures.gql +++ b/src/graphql/Dashboard/flow-failures.gql @@ -4,10 +4,10 @@ query FlowFailures($projectId: uuid, $heartbeat: timestamptz, $tenantId: uuid) { tenant_id: { _eq: $tenantId } flow: { project_id: { _eq: $projectId } } state: { _eq: "Failed" } - start_time: { _gte: $heartbeat } + scheduled_start_time: { _gte: $heartbeat } } distinct_on: flow_id - order_by: { flow_id: asc, start_time: desc } + order_by: { flow_id: asc, scheduled_start_time: desc } ) { flow_id state_timestamp @@ -18,6 +18,6 @@ query FlowFailures($projectId: uuid, $heartbeat: timestamptz, $tenantId: uuid) { flow_group_id } - start_time + scheduled_start_time } } diff --git a/src/pages/Dashboard/FailedFlows-Tile.vue b/src/pages/Dashboard/FailedFlows-Tile.vue index 1ad98c710..bf2988913 100644 --- a/src/pages/Dashboard/FailedFlows-Tile.vue +++ b/src/pages/Dashboard/FailedFlows-Tile.vue @@ -123,7 +123,7 @@ export default { - Filter on flow run start time + Filter on flow run scheduled start time