From b28d8b127f5ce02e491dbd8a644f72441a73921e Mon Sep 17 00:00:00 2001 From: Danny Avila Date: Tue, 28 Jul 2026 09:56:09 -0400 Subject: [PATCH] =?UTF-8?q?=F0=9F=A7=B9=20chore:=20Alias=20the=20Retry-Fra?= =?UTF-8?q?me=20Set=20for=20the=20Effect=20Cleanup=20Lint=20Rule?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client/src/hooks/SSE/useResumableSSE.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/client/src/hooks/SSE/useResumableSSE.ts b/client/src/hooks/SSE/useResumableSSE.ts index efcb5f7d64..b0cebbd71d 100644 --- a/client/src/hooks/SSE/useResumableSSE.ts +++ b/client/src/hooks/SSE/useResumableSSE.ts @@ -1882,6 +1882,10 @@ export default function useResumableSSE( initStream(); + /** The Set object itself is never reassigned, so this alias reads the + * LIVE frame ids at cleanup time (satisfies react-hooks/exhaustive-deps + * without changing behavior). */ + const activityLabelRetryFrames = activityLabelRetryFramesRef.current; return () => { logger.log('ResumableSSE', 'Cleanup - closing SSE, resetting UI state'); startController.abort(); @@ -1896,10 +1900,10 @@ export default function useResumableSSE( cancelAnimationFrame(pendingActionRetryRef.current); pendingActionRetryRef.current = null; } - for (const frameId of activityLabelRetryFramesRef.current) { + for (const frameId of activityLabelRetryFrames) { cancelAnimationFrame(frameId); } - activityLabelRetryFramesRef.current.clear(); + activityLabelRetryFrames.clear(); if (steerRetryRef.current != null) { cancelAnimationFrame(steerRetryRef.current); steerRetryRef.current = null;