Index of every page on this site: llms.txt
All skills
jeremylongshore avatar

/sentry-common-errors

@0d57af8
Run it yourself

Troubleshoot common Sentry integration issues and fixes. Use when encountering Sentry errors, missing events, source map failures, rate limits, or configuration problems. Trigger: "sentry not working", "sentry errors missing", "fix sentry", "sentry troubleshoot", "sentry 429", "source maps not resolving", "sentry events not showing", "sentry flush", "sentry CORS".

Use this Skill: https://skilld.dev/gh/jeremylongshore/tons-of-skills-marketplace/sentry-common-errors

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencescommon-issues-and-solutions.md

≈673 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Common Issues and Solutions

DSN Configuration Problems

Symptom Root Cause Fix
"No DSN provided" in debug output Env var name typo or not loaded Verify process.env.SENTRY_DSN is set. Check .env file loading order
"Invalid Sentry Dsn" exception Malformed DSN string Re-copy from Project Settings > Client Keys. Format: https://<key>@<org>.ingest.sentry.io/<id>
SDK initializes but no events DSN has trailing whitespace Trim the value: dsn: process.env.SENTRY_DSN.trim()
Events go to wrong project DSN copied from wrong project Each project has a unique DSN. Verify in Project Settings

Events Not Appearing

beforeSend Dropping Events

The most common cause of "silently missing" events. The function must return event or null on every code path.

// WRONG — undefined return drops event
beforeSend(event) {
  if (event.exception) {
    return event;
  }
  // Missing return = undefined = event dropped
}

// CORRECT
beforeSend(event) {
  if (event.message?.includes('ResizeObserver')) return null;
  return event;
}

sampleRate Misconfiguration

  • sampleRate: 0 — drops 100% of error events
  • sampleRate: 1.0 — sends all errors (default, recommended)
  • tracesSampleRate: 0 — disables performance monitoring (OK if you only want errors)

Process Exit Before Flush

Applies to: CLI tools, cron jobs, AWS Lambda, Google Cloud Functions, Azure Functions.

await Sentry.flush(2000); // Always flush before exit
sentry_sdk.flush(timeout=2)

Source Map Failures

Diagnosis Command

sentry-cli sourcemaps explain --org "$SENTRY_ORG" --project "$SENTRY_PROJECT" EVENT_ID

Common Mismatches

  1. Release mismatch — Sentry.init({ release }) must match sentry-cli releases new
  2. URL prefix mismatch — --url-prefix must match the browser URL path
  3. Upload timing — source maps must be uploaded BEFORE the release goes live
  4. Missing source maps — verify build generates .map files

Import Order Issues

Sentry SDK v8 uses Node.js module hooks. It must be imported before any other module.

node --import ./instrument.mjs app.mjs

Rate Limiting (429)

sampleRate: 0.5,          // 50% error sampling
tracesSampleRate: 0.01,   // 1% transaction sampling
ignoreErrors: [...],      // Filter known noise

Server-side: Settings > Projects > [Project] > Client Keys > Configure > Rate Limiting


Tons of Skills by Intent Solutions | jeremylongshore.com

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

1 alert2mo3 checks · Risk HIGH
  • Gen Agent Trust Hub2mo

    The skill facilitates troubleshooting for Sentry integrations by checking environment configurations and service status. It performs diagnostic scans of local project files to identify Sentry initialization patterns, which introduces a minor indirect prompt injection risk. It also uses official Sentry status APIs for health checks.

  • Socket2mo

    No alerts

  • Snyk2mo

    Risk: LOW · No issues

Signed by skilld at 0d57af8. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub yesterday.

Activeupdated 3 months ago
What it can do
Reads files Runs commands
version
1.51.0
author
Jeremy Longshore <jeremy@intentsolutions.io>
compatibility
Designed for Claude Code
All 8 allowed tools
ReadGrepBash(npm:*)Bash(node:*)Bash(curl:*)Bash(npx:*)Bash(sentry-cli:*)Bash(python3:*)
Other metadata
tags
[
  "saas",
  "sentry",
  "troubleshooting",
  "debugging",
  "error-monitoring"
]

README badge

README badge for jeremylongshore/tons-of-skills-marketplace/sentry-common-errors