From 3b8d937dd2788dfa97ea497bdaeca2bf36bb7a14 Mon Sep 17 00:00:00 2001 From: Ruben Fiszel Date: Sat, 23 May 2026 09:26:04 +0000 Subject: [PATCH] feat: job-id link + dispatch popover above script log/result --- .../src/lib/components/ScriptEditor.svelte | 25 ++++++ .../assets/AssetGraph/AssetRunsPanel.svelte | 7 ++ .../runs/DispatchEventsButton.svelte | 48 ++++++++++ .../runs/DispatchEventsPanel.svelte | 84 +---------------- .../runs/DispatchEventsTable.svelte | 90 +++++++++++++++++++ 5 files changed, 172 insertions(+), 82 deletions(-) create mode 100644 frontend/src/lib/components/runs/DispatchEventsButton.svelte create mode 100644 frontend/src/lib/components/runs/DispatchEventsTable.svelte diff --git a/frontend/src/lib/components/ScriptEditor.svelte b/frontend/src/lib/components/ScriptEditor.svelte index 88436327d4..c1cb4c7255 100644 --- a/frontend/src/lib/components/ScriptEditor.svelte +++ b/frontend/src/lib/components/ScriptEditor.svelte @@ -83,6 +83,7 @@ import { setContext } from 'svelte' import HideButton from './apps/editor/settingsPanel/HideButton.svelte' import { base } from '$lib/base' + import DispatchEventsButton from '$lib/components/runs/DispatchEventsButton.svelte' import { SUPPORTED_CHAT_SCRIPT_LANGUAGES } from './copilot/chat/script/core' import { getStringError } from './copilot/chat/utils' import type { ScriptOptions } from './copilot/chat/ContextManager.svelte' @@ -1810,6 +1811,30 @@ it visually pinned to the top edge without relying on cross-browser overflow behaviour. -->
+ {#if testJob?.id && testJob.type === 'CompletedJob' && $workspaceStore} + + + {/if}
{#if testIsLoading} + {/snippet} + {#snippet content()} +
+ +
+ {/snippet} + +{/if} diff --git a/frontend/src/lib/components/runs/DispatchEventsPanel.svelte b/frontend/src/lib/components/runs/DispatchEventsPanel.svelte index e24ee15579..545ff35488 100644 --- a/frontend/src/lib/components/runs/DispatchEventsPanel.svelte +++ b/frontend/src/lib/components/runs/DispatchEventsPanel.svelte @@ -1,8 +1,7 @@ {#if list.length > 0}

Dispatch

- - - - - - - - - - - {#each list as ev (ev.created_at + ev.subscriber_path + ev.asset_path)} - - - - - - - {/each} - -
OutcomeSubscriberAssetDetail
- {#if ev.outcome === 'dispatched'} - - dispatched - - {:else if ev.outcome === 'join_pending'} - - join pending - - {:else} - - skipped - - {/if} - - {ev.subscriber_path} - - {ev.asset_kind}://{ev.asset_path} - - {#if ev.outcome === 'dispatched' && ev.child_job_id} - - {ev.child_job_id.slice(0, 8)}… - - - {#if ev.partition} - - · partition {ev.partition} - {/if} - {#if ev.debounce_s && ev.debounce_s > 0} - · debounced {ev.debounce_s}s - {/if} - {:else if ev.outcome === 'join_pending'} - {ev.received_inputs ?? 0}/{ev.required_inputs ?? 0} inputs received - {#if ev.partition} - - for partition {ev.partition} - {/if} - {:else} - {reasonLabel(ev.reason)} - {/if} -
+
{/if} diff --git a/frontend/src/lib/components/runs/DispatchEventsTable.svelte b/frontend/src/lib/components/runs/DispatchEventsTable.svelte new file mode 100644 index 0000000000..6ed288a6b8 --- /dev/null +++ b/frontend/src/lib/components/runs/DispatchEventsTable.svelte @@ -0,0 +1,90 @@ + + + + + + + + + + + + + {#each events as ev (ev.created_at + ev.subscriber_path + ev.asset_path)} + + + + + + + {/each} + +
OutcomeSubscriberAssetDetail
+ {#if ev.outcome === 'dispatched'} + + dispatched + + {:else if ev.outcome === 'join_pending'} + + join pending + + {:else} + + skipped + + {/if} + + {ev.subscriber_path} + + {ev.asset_kind}://{ev.asset_path} + + {#if ev.outcome === 'dispatched' && ev.child_job_id} + + {ev.child_job_id.slice(0, 8)}… + + + {#if ev.partition} + + · partition {ev.partition} + {/if} + {#if ev.debounce_s && ev.debounce_s > 0} + · debounced {ev.debounce_s}s + {/if} + {:else if ev.outcome === 'join_pending'} + {ev.received_inputs ?? 0}/{ev.required_inputs ?? 0} inputs received + {#if ev.partition} + + for partition {ev.partition} + {/if} + {:else} + {reasonLabel(ev.reason)} + {/if} +