Closed michael-maust closed 5 months ago
After adding the supabaseIntegration to Sentry in my React/Vite app, I get this error:
supabaseIntegration
@supabase_sentry-js-integration.js?v=e11811c9:13 Uncaught TypeError: AVAILABLE_OPERATIONS is not iterable at @supabase_sentry-js-integration.js?v=e11811c9:13:19
Here's the Sentry.Init:
import { useEffect } from 'react' import * as Sentry from '@sentry/react' import { env as supabaseEnv } from '@service/supabase' import { client as supabaseClient } from '@service/supabase' import { supabaseIntegration } from '@supabase/sentry-js-integration' import { SupabaseClient } from '@supabase/supabase-js' import { createRoutesFromChildren, matchRoutes, useLocation, useNavigationType, } from 'react-router-dom' import env from '../env' export function InitializeSentry() { console.log('Initializing Sentry...', ...[env.BASE_URL, env.API_URL, supabaseEnv.SUPABASE_URL]) Sentry.init({ debug: true, dsn: env.SENTRY_DSN_URL, // enabled: env.MODE !== 'development', // Performance Monitoring environment: env.MODE, release: __APP_VERSION__, // Session Replay replaysSessionSampleRate: 1.0, replaysOnErrorSampleRate: 1.0, integrations: [ supabaseIntegration(SupabaseClient, Sentry, { tracing: true, breadcrumbs: true, errors: true, }), Sentry.browserProfilingIntegration(), Sentry.replayIntegration({ maskAllText: false, blockAllMedia: false, maskAllInputs: false, networkDetailAllowUrls: [env.BASE_URL, env.API_URL, supabaseEnv.SUPABASE_URL], networkDetailDenyUrls: [ 'https://www.facebook.com/', 'https://app.hubspot.com/', 'https://www.google-analytics.com/', ], }), Sentry.replayCanvasIntegration(), Sentry.reactRouterV6BrowserTracingIntegration({ useEffect, useLocation, useNavigationType, createRoutesFromChildren, matchRoutes, shouldCreateSpanForRequest: (url) => { return !url.startsWith(`${supabaseEnv.SUPABASE_URL}/rest`) }, }), ], }) }
Fixed thanks to @etzelc, released in 0.2.0-beta.3
0.2.0-beta.3
Bug report
Describe the bug
After adding the
supabaseIntegration
to Sentry in my React/Vite app, I get this error:Here's the Sentry.Init:
System information