diff --git a/autogpt_platform/frontend/instrumentation-client.ts b/autogpt_platform/frontend/instrumentation-client.ts index b8a7fc9f4d11..3e601b11360d 100644 --- a/autogpt_platform/frontend/instrumentation-client.ts +++ b/autogpt_platform/frontend/instrumentation-client.ts @@ -31,7 +31,7 @@ Sentry.init({ Sentry.extraErrorDataIntegration(), Sentry.browserProfilingIntegration(), Sentry.httpClientIntegration(), - // Sentry.launchDarklyIntegration(), + Sentry.launchDarklyIntegration(), Sentry.replayIntegration({ unmask: [".sentry-unmask, [data-sentry-unmask]"], }), diff --git a/autogpt_platform/frontend/src/services/feature-flags/feature-flag-provider.tsx b/autogpt_platform/frontend/src/services/feature-flags/feature-flag-provider.tsx index 9a3fdfd52a0d..69295cbb0f95 100644 --- a/autogpt_platform/frontend/src/services/feature-flags/feature-flag-provider.tsx +++ b/autogpt_platform/frontend/src/services/feature-flags/feature-flag-provider.tsx @@ -5,6 +5,7 @@ import type { ReactNode } from "react"; import { useMemo } from "react"; import { useSupabase } from "@/lib/supabase/hooks/useSupabase"; import { BehaveAs, getBehaveAs } from "@/lib/utils"; +import * as Sentry from "@sentry/nextjs"; const clientId = process.env.NEXT_PUBLIC_LAUNCHDARKLY_CLIENT_ID; const envEnabled = process.env.NEXT_PUBLIC_LAUNCHDARKLY_ENABLED === "true"; @@ -45,7 +46,10 @@ export function LaunchDarklyProvider({ children }: { children: ReactNode }) { clientSideID={clientId} context={context} reactOptions={{ useCamelCaseFlagKeys: false }} - options={{ bootstrap: "localStorage" }} + options={{ + bootstrap: "localStorage", + inspectors: [Sentry.buildLaunchDarklyFlagUsedHandler()], + }} > {children}