sentry
Assists with monitoring application errors, performance, and user experience using Sentry. Use when integrating Sentry SDKs, configuring alerting, analyzing stack traces, uploading source maps, or tracking release health in production. Trigger words: sentry, error monitoring, error tracking, performance monitoring, source maps, session replay.
What this skill does
# Sentry ## Overview Sentry is an error monitoring and performance platform that captures unhandled exceptions, tracks request performance with Web Vitals, records session replays, and alerts on regressions. It supports JavaScript, Python, Go, and mobile platforms with auto-instrumentation, source-mapped stack traces, and release health tracking. ## Instructions - When integrating the SDK, call `Sentry.init()` with `dsn`, `environment`, `release`, and `tracesSampleRate`, choosing the framework-specific SDK (`@sentry/nextjs`, `@sentry/sveltekit`, `sentry-sdk` for Python) for automatic instrumentation. - When configuring error tracking, set up `Sentry.setUser()` after login for user correlation, add custom tags with `Sentry.setTag()` for filtering, and configure `ignoreErrors` for known harmless errors from browser extensions and third-party scripts. - When uploading source maps, use `@sentry/vite-plugin` or `@sentry/webpack-plugin` in the CI build step to map minified stack traces back to original source code, associating them with the release version. - When monitoring performance, set `tracesSampleRate` to 0.1-0.2 in production, add custom spans with `Sentry.startSpan()` for business-critical operations, and monitor Web Vitals (LCP, CLS, INP) for real user experience. - When setting up alerts, configure rules for error rate spikes rather than individual errors, integrate with Slack or PagerDuty, and filter by environment and error level. - When using session replay, set `replaysOnErrorSampleRate: 1.0` for all error sessions and `replaysSessionSampleRate: 0.1` for general sampling, with privacy masking for sensitive data. ## Examples ### Example 1: Set up Sentry for a Next.js production app **User request:** "Add Sentry error monitoring and performance tracking to my Next.js app" **Actions:** 1. Install `@sentry/nextjs` and run the setup wizard to configure `sentry.client.config.ts` and `sentry.server.config.ts` 2. Configure `Sentry.init()` with environment, release, and `tracesSampleRate: 0.2` 3. Add source map upload to the CI build pipeline with `@sentry/nextjs` webpack integration 4. Set up Slack alerts for error rate spikes in the production environment **Output:** A Next.js app with automatic error capture, source-mapped stack traces, performance monitoring, and Slack alerting. ### Example 2: Track release health and identify regressions **User request:** "Set up release tracking to identify which deployment introduced a bug" **Actions:** 1. Configure `release` in `Sentry.init()` using the git commit SHA or semantic version 2. Integrate with GitHub to link releases to commits for suspect commit detection 3. Set up deploy tracking to mark when releases go to staging and production 4. Configure regression alerts that notify when a previously resolved issue reappears **Output:** Release health monitoring with crash-free session tracking, suspect commits, and regression alerts. ## Guidelines - Set `tracesSampleRate` to 0.1-0.2 in production since 100% sampling is expensive and unnecessary. - Upload source maps in CI since unreadable minified stack traces are not useful for debugging. - Set `environment` and `release` on every `Sentry.init()` call to filter errors by staging versus production. - Use `Sentry.setUser()` after login to correlate errors with specific users for support. - Configure alert rules for error rate spikes rather than individual errors to reduce noise. - Set `ignoreErrors` for known harmless errors from browser extensions, network timeouts, and third-party scripts.
Related in Data & Analytics
clawarr-suite
IncludedComprehensive management for self-hosted media stacks (Sonarr, Radarr, Lidarr, Readarr, Prowlarr, Bazarr, Overseerr, Plex, Tautulli, SABnzbd, Recyclarr, Unpackerr, Notifiarr, Maintainerr, Kometa, FlareSolverr). Deep library exploration, analytics, dashboard generation, content management, request handling, subtitle management, indexer control, download monitoring, quality profile sync, library cleanup automation, notification routing, collection/overlay management, and media tracker integration (Trakt, Letterboxd, Simkl).
querying-soql
IncludedSOQL query generation, optimization, and analysis with 100-point scoring. Use this skill when the user needs SOQL/SOSL authoring or optimization: natural-language-to-query generation, relationship queries, aggregates, query-plan analysis, and performance or safety improvements for Salesforce queries. TRIGGER when: user writes, optimizes, or debugs SOQL/SOSL queries, touches .soql files, or asks about relationship queries, aggregates, or query performance. DO NOT TRIGGER when: bulk data operations (use handling-sf-data), Apex DML logic (use generating-apex), or report/dashboard queries.
app-store-optimization
IncludedApp Store Optimization (ASO) toolkit for researching keywords, analyzing competitor rankings, generating metadata suggestions, and improving app visibility on Apple App Store and Google Play Store. Use when the user asks about ASO, app store rankings, app metadata, app titles and descriptions, app store listings, app visibility, or mobile app marketing on iOS or Android. Supports keyword research and scoring, competitor keyword analysis, metadata optimization, A/B test planning, launch checklists, and tracking ranking changes.
habit-flow
IncludedAI-powered atomic habit tracker with natural language logging, streak tracking, smart reminders, and coaching. Use for creating habits, logging completions naturally ("I meditated today"), viewing progress, and getting personalized coaching.
app-store-optimization
IncludedApp Store Optimization (ASO) toolkit for researching keywords, analyzing competitor rankings, generating metadata suggestions, and improving app visibility on Apple App Store and Google Play Store. Use when the user asks about ASO, app store rankings, app metadata, app titles and descriptions, app store listings, app visibility, or mobile app marketing on iOS or Android. Supports keyword research and scoring, competitor keyword analysis, metadata optimization, A/B test planning, launch checklists, and tracking ranking changes.
visualizing-data
IncludedBuilds dashboards, reports, and data-driven interfaces requiring charts, graphs, or visual analytics. Provides systematic framework for selecting appropriate visualizations based on data characteristics and analytical purpose. Includes 24+ visualization types organized by purpose (trends, comparisons, distributions, relationships, flows, hierarchies, geospatial), accessibility patterns (WCAG 2.1 AA compliance), colorblind-safe palettes, and performance optimization strategies. Use when creating visualizations, choosing chart types, displaying data graphically, or designing data interfaces.