Skip to content

fix(web): filter benign ResizeObserver loop warning from PostHog - #2783

Merged
tyler-dane merged 1 commit into
mainfrom
claude/resize-observer-error-a47b2b
Aug 14, 2026
Merged

fix(web): filter benign ResizeObserver loop warning from PostHog#2783
tyler-dane merged 1 commit into
mainfrom
claude/resize-observer-error-a47b2b

Conversation

@tyler-dane

Copy link
Copy Markdown
Contributor

Summary

  • Reported via PostHog/Discord: ResizeObserver loop completed with undelivered notifications. was showing up as a tracked error.
  • This is a well-known, non-actionable browser warning — Chrome/Firefox fire it via window.onerror when a ResizeObserver callback can't finish its notification cycle within one frame. Nothing actually threw. Since PostHog's capture_unhandled_errors listens on window.onerror, it was picked up and reported as a real exception.
  • Added this signature (plus the older Firefox variant ResizeObserver loop limit exceeded) to the existing droppable-exception filter, alongside the other known-benign browser signatures already filtered there (CefSharp scanner noise, opaque cross-origin Script error., SuperTokens network blips).

Investigation also found several likely sources of the observer activity (grid measurement hooks with a measure→setState→resize cycle, floating-ui autoUpdate on tooltips/menus) — these are expected in an app with dynamic, size-driven layout and not something to remove; only the reporting-side false positive is fixed here.

Simplicity

Minimal fix: two string constants + one conditional check, following the exact existing pattern in posthog-exception-filter.util.ts (no new abstractions, no changes to the layout/observer code).

Automated validation

N/A — this is error-filtering config, not a UI change; no browser-observable behavior to verify.

Independent review

Not run for this change.

Test plan

  • TZ=UTC NODE_ENV=test bun test ./src/auth/posthog/posthog-exception-filter.util.test.ts (from packages/web) — 12 pass, 0 fail (2 new tests added)
  • bun run type-check — clean

Chrome/Firefox report "ResizeObserver loop completed with undelivered
notifications." via window.onerror even though nothing threw. PostHog's
capture_unhandled_errors picks it up and reports it as a real exception.
Add it to the existing droppable-exception filter alongside the other
known-benign browser signatures.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@tyler-dane
tyler-dane merged commit fc00c04 into main Aug 14, 2026
20 checks passed
@tyler-dane
tyler-dane deleted the claude/resize-observer-error-a47b2b branch August 14, 2026 12:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant