-
[OPIK-5903] [FE] fix: stabilize filters default to prevent trace panel crash (#6284)
发布于
2026-04-15 09:17:37 +00:00 The inline
filters = []destructuring default in TraceDetailsPanel and
TracesSpansTab produced a fresh array reference every render when the URL
param was absent. When Ollie navigates with a narrow search payload, the
stripped params cascade through simultaneousreplaceInwrite-backs; the
unstablefiltersreference amplifies that into a re-render storm that
exceeds React's nested-update limit, caught in a Tooltip-wrapped button's
composed ref chain ("Maximum update depth exceeded" on the trace page).Replace the inline default with a module-level
EMPTY_FILTERSconstant so
the fallback reference is stable across renders.setFiltersstill writes
to the URL, so the constant is never mutated.Co-authored-by: Claude Opus 4.6 (1M context) noreply@anthropic.com
下载附件