From 1a59017e1c9f22e800439fbbe631b7e9299a69e0 Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Tue, 17 Mar 2026 18:41:06 +0100 Subject: [PATCH] :bug: Ignore posthog exceptions in unhandled exception handler (#8629) PostHog recorder throws errors like 'Cannot assign to read only property 'assert' of object' which are unrelated to the application and should be ignored to prevent noise in error reporting. --- frontend/src/app/main/errors.cljs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/frontend/src/app/main/errors.cljs b/frontend/src/app/main/errors.cljs index fe5a82518e..abed794099 100644 --- a/frontend/src/app/main/errors.cljs +++ b/frontend/src/app/main/errors.cljs @@ -337,9 +337,15 @@ (or (str/includes? stack "chrome-extension://") (str/includes? stack "moz-extension://"))))) + (from-posthog? [cause] + (let [stack (.-stack cause)] + (and (string? stack) + (str/includes? stack "posthog")))) + (is-ignorable-exception? [cause] (let [message (ex-message cause)] (or (from-extension? cause) + (from-posthog? cause) (= message "Possible side-effect in debug-evaluate") (= message "Unexpected end of input") (str/starts-with? message "invalid props on component")