From 7f9332ed6f16b325c2f03b61fc6b7ffcd2bd3456 Mon Sep 17 00:00:00 2001 From: Yicheng-Lu-llll Date: Sat, 24 Jun 2023 04:12:00 +0000 Subject: [PATCH 1/2] feat: real time deck support Signed-off-by: Yicheng-Lu-llll --- .../Executions/ExecutionDetails/ExecutionDetailsActions.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/console/src/components/Executions/ExecutionDetails/ExecutionDetailsActions.tsx b/packages/console/src/components/Executions/ExecutionDetails/ExecutionDetailsActions.tsx index 8fd46e07d..30805a31d 100644 --- a/packages/console/src/components/Executions/ExecutionDetails/ExecutionDetailsActions.tsx +++ b/packages/console/src/components/Executions/ExecutionDetails/ExecutionDetailsActions.tsx @@ -163,7 +163,6 @@ export const ExecutionDetailsActions = ({ variant="outlined" color="primary" onClick={() => setShowDeck(true)} - disabled={phase !== NodeExecutionPhase.SUCCEEDED} > {text?.flyteDeckText || t('flyteDeck')} From 20c6ff6f13154c374ca8b22bb3f6df9586fcfa19 Mon Sep 17 00:00:00 2001 From: Yicheng-Lu-llll Date: Thu, 29 Jun 2023 22:35:11 +0000 Subject: [PATCH 2/2] feat: add deck uri not exists case Signed-off-by: Yicheng-Lu-llll --- .../ExecutionDetails/ExecutionNodeDeck.tsx | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/packages/console/src/components/Executions/ExecutionDetails/ExecutionNodeDeck.tsx b/packages/console/src/components/Executions/ExecutionDetails/ExecutionNodeDeck.tsx index 2a389fd2c..41c2fb730 100644 --- a/packages/console/src/components/Executions/ExecutionDetails/ExecutionNodeDeck.tsx +++ b/packages/console/src/components/Executions/ExecutionDetails/ExecutionNodeDeck.tsx @@ -2,6 +2,7 @@ import { useDownloadLink } from 'components/hooks/useDataProxy'; import { WaitForData } from 'components/common/WaitForData'; import * as React from 'react'; import { Core } from '@flyteorg/flyteidl-types'; +import { NotFoundError } from 'errors/fetchErrors'; /** Fetches and renders the deck data for a given `nodeExecutionId` */ export const ExecutionNodeDeck: React.FC<{ @@ -10,6 +11,22 @@ export const ExecutionNodeDeck: React.FC<{ }> = ({ nodeExecutionId, className = '' }) => { const downloadLink = useDownloadLink(nodeExecutionId); + if (downloadLink?.lastError instanceof NotFoundError) { + return ( +
+

The deck will be ready soon. Please try again later.

+

+ If you're using the real-time deck, it's because the 'persist' + function has not been invoked yet. +

+

+ If you're not using the real-time deck, it's because the corresponding + task is still in progress. +

+
+ ); + } + return (