From d9c7d71f072b0562bb3b1642cfdc961a8948671b Mon Sep 17 00:00:00 2001 From: Diego Imbert <70353967+diegoimbert@users.noreply.github.com> Date: Mon, 28 Sep 2026 17:23:59 +0200 Subject: [PATCH] fix: redesign run not found page and fix switching to the right workspace (#11374) * fix: redesign run not found page and clear stale not-found on workspace switch Co-Authored-By: Claude Opus 5.5 (1M context) * refactor: use design-system Button for workspace rows on run not found page Co-Authored-By: Claude Opus 5.5 (1M context) --------- Co-authored-by: Claude Opus 5.5 (1M context) --- frontend/src/lib/components/JobLoader.svelte | 5 ++ .../(root)/(logged)/run/[...run]/+page.svelte | 61 +++++++++++++------ 2 files changed, 47 insertions(+), 19 deletions(-) diff --git a/frontend/src/lib/components/JobLoader.svelte b/frontend/src/lib/components/JobLoader.svelte index 0994905121..c59f4266b7 100644 --- a/frontend/src/lib/components/JobLoader.svelte +++ b/frontend/src/lib/components/JobLoader.svelte @@ -411,6 +411,8 @@ errorIteration = 0 currentId = testId scriptProgress = undefined + notfound = false + loadError = undefined // Replay mode: feed recorded events instead of real SSE const replay = getActiveReplay() @@ -727,6 +729,9 @@ }), noLogs ) + // The completed-job branch below returns before the end of this block. + notfound = false + loadError = undefined callbacks?.change?.(job) } diff --git a/frontend/src/routes/(root)/(logged)/run/[...run]/+page.svelte b/frontend/src/routes/(root)/(logged)/run/[...run]/+page.svelte index 5fc7c1209d..183d10a003 100644 --- a/frontend/src/routes/(root)/(logged)/run/[...run]/+page.svelte +++ b/frontend/src/routes/(root)/(logged)/run/[...run]/+page.svelte @@ -41,8 +41,11 @@ Share2, Globe, Users, - Play + Play, + SearchX, + ArrowRight } from 'lucide-svelte' + import WorkspaceIcon from '$lib/components/workspace/WorkspaceIcon.svelte' import { forLater } from '$lib/forLater' import { isJobResolvable } from '$lib/utils' @@ -751,30 +754,50 @@ {:else if notfound || (job?.workspace_id != undefined && $workspaceStore != undefined && job?.workspace_id != $workspaceStore)} -
-
-

Job {page.params.run} not found in {$workspaceStore}

-

Are you in the right workspace?

-
- {#each $userWorkspaces as workspace} -
+ {@const currentWorkspace = $userWorkspaces.find((w) => w.id === $workspaceStore)} + {@const otherWorkspaces = $userWorkspaces.filter((w) => w.id !== $workspaceStore)} +
+
+
+ +
+

Run not found

+

+ No run with ID + {page.params.run} + exists in + {currentWorkspace?.name ?? $workspaceStore}. It may belong to another workspace, or it may have been deleted. +

+
+ + {#if otherWorkspaces.length > 0} +
+

Look in another workspace

+
+ {#each otherWorkspaces as workspace (workspace.id)} -
- {/each} -
- + {/each}
+ {/if} + +
+
{:else}