diff --git a/src/pages/admin/PlatformStackView.tsx b/src/pages/admin/PlatformStackView.tsx index b545e5c..5a04082 100644 --- a/src/pages/admin/PlatformStackView.tsx +++ b/src/pages/admin/PlatformStackView.tsx @@ -457,8 +457,9 @@ export function PlatformStackView() { return () => clearInterval(iv) }, [settled, load]) - // Reconnect the log stream on every status change — each pipeline step is - // its own Job and its own pod, so the previous stream has already ended. + // Reconnect when either the pipeline step or Registry sub-step changes — + // Registry preparation runs several Jobs while status stays step_vtc_setup, + // then the minted DID switches the source back to the VTC setup Job. const sessionId = stack?.id useEffect(() => { if (!sessionId || status === 'failed' || status === 'awaiting_admin_did') return @@ -474,7 +475,7 @@ export function PlatformStackView() { es.addEventListener('done', () => es.close()) es.onerror = () => es.close() return () => es.close() - }, [sessionId, status, logStreamGeneration]) + }, [sessionId, status, stack?.trust_registry?.phase, stack?.trust_registry?.did, logStreamGeneration]) function reconnectVtaLogs() { setLogs([]) diff --git a/src/pages/portal/FullStackCreateProgress.tsx b/src/pages/portal/FullStackCreateProgress.tsx index e608c9c..2f28547 100644 --- a/src/pages/portal/FullStackCreateProgress.tsx +++ b/src/pages/portal/FullStackCreateProgress.tsx @@ -29,7 +29,9 @@ export function FullStackCreateProgress({ sessionId, vtaName }: { sessionId: str return () => clearInterval(iv) }, [sessionId]) - // Reconnect the log stream whenever the raw status changes — each step is its own Job/pod. + // Registry preparation runs several Jobs without changing the raw session + // status; its phase selects those Jobs, and its minted DID switches the + // source back to the VTC setup Job. useEffect(() => { if (!session || session.status === 'failed' || session.status === 'awaiting_admin_did') return // Clear when the stream actually opens rather than up front: the previous @@ -43,10 +45,10 @@ export function FullStackCreateProgress({ sessionId, vtaName }: { sessionId: str es.addEventListener('done', () => es.close()) es.onerror = () => es.close() return () => es.close() - // Keyed on the status, not the object: the 3s poll replaces `session` every - // tick, so depending on it would reconnect this stream continuously. + // Keyed on scalar progress fields, not the object: the 3s poll replaces + // `session` every tick, which would reconnect this stream continuously. // eslint-disable-next-line react-hooks/exhaustive-deps - }, [sessionId, session?.status]) + }, [sessionId, session?.status, session?.trust_registry?.phase, session?.trust_registry?.did]) // Scroll only within the console body — not the whole page — as new lines arrive. useEffect(() => { diff --git a/src/pages/portal/SessionDetailView.tsx b/src/pages/portal/SessionDetailView.tsx index f9f1357..6a7fda3 100644 --- a/src/pages/portal/SessionDetailView.tsx +++ b/src/pages/portal/SessionDetailView.tsx @@ -146,10 +146,10 @@ function SessionDetailContent() { es.addEventListener('done', () => es.close()) es.onerror = () => es.close() return () => es.close() - // Keyed on the status, not the object: the 3s poll replaces `session` every - // tick, so depending on it would reconnect this stream continuously. + // Keyed on scalar progress fields, not the object: the 3s poll replaces + // `session` every tick, which would reconnect this stream continuously. // eslint-disable-next-line react-hooks/exhaustive-deps - }, [sessionId, session?.status, logStreamGeneration]) + }, [sessionId, session?.status, session?.trust_registry?.phase, session?.trust_registry?.did, logStreamGeneration]) function reconnectVtaLogs() { setLogs([])