diff --git a/ui/src/workflows/WorkflowEditor.vue b/ui/src/workflows/WorkflowEditor.vue index 3fc1f01dc..648f5089c 100644 --- a/ui/src/workflows/WorkflowEditor.vue +++ b/ui/src/workflows/WorkflowEditor.vue @@ -85,7 +85,11 @@ const localError = ref(""); const { runs, error: runsError, loading: runsLoading, watched, watchedRun, stages, attempt, pick, follow, refresh } = useWorkflowRuns(selected); const stepTab = ref("definition"); -const graph = computed(() => withRuns(workflowGraph(yaml.value), stages.value)); +// A run without a pinned definition cannot be matched to the drawn steps, so +// the canvas draws the definition alone. +const unpinned = computed(() => Boolean(watchedRun.value && !watchedRun.value.workflow_definition_yaml)); +const drawnStages = computed(() => unpinned.value ? [] : stages.value); +const graph = computed(() => withRuns(workflowGraph(yaml.value), drawnStages.value)); function toggle(key: string): void { open.value = open.value === key ? null : key; const run = graph.value.nodes.find((node) => JSON.stringify(node.data.path ?? null) === open.value)?.data.run; @@ -445,7 +449,7 @@ function syncScroll(event: Event): void {
Could not load recent runs: {{ runsError }}
-No workflow snapshot was recorded for this run.
+No workflow snapshot was recorded for this run.