From 104bd5fbb1b03f1c40ca2746cfea290cd6537a33 Mon Sep 17 00:00:00 2001 From: Ruben Fiszel Date: Tue, 3 Mar 2026 13:25:17 +0000 Subject: [PATCH] fix: clean up slow-load toast interval on component destroy (#8207) The slowStreamIntervalId (which fires "Loading is taking a long time..." toasts every 15s) was not cleared in onDestroy, causing it to keep firing after navigating away from the runs page. Co-authored-by: Claude Opus 4.6 --- frontend/src/lib/components/runs/useJobsLoader.svelte.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/frontend/src/lib/components/runs/useJobsLoader.svelte.ts b/frontend/src/lib/components/runs/useJobsLoader.svelte.ts index 5e9aa29222..9c0abb2015 100644 --- a/frontend/src/lib/components/runs/useJobsLoader.svelte.ts +++ b/frontend/src/lib/components/runs/useJobsLoader.svelte.ts @@ -666,6 +666,11 @@ export function useJobsLoader(args: () => UseJobLoaderArgs) { if (intervalId) { clearInterval(intervalId) } + if (slowStreamIntervalId) { + clearInterval(slowStreamIntervalId) + slowStreamIntervalId = undefined + } + paramChangePromise?.cancel() }) $effect(() => { Object.keys(filters ?? {}).map((k) => filters?.[k as keyof RunsFilterInstance])