ERR-005 recommended Setup

Deployment integration with Sentry

Releases created in Sentry, deploy notifications sent, errors filterable by release

Question to ask

"Did errors spike after your last deploy, and did you catch it?"

Verification guide

Severity: Recommended

When Sentry knows about deployments, you can answer "did this deploy break something?" and filter errors by release.

Check automatically:

  1. Check for release creation in CI/CD:
# Sentry release in CI
grep -riE "sentry-cli.*releases|sentry.*release|SENTRY_RELEASE" .github/workflows/*.yml .gitlab-ci.yml 2>/dev/null
  1. Check for release config in Sentry init:
# Release in Sentry.init
grep -A 30 "Sentry.init" --include="*.ts" --include="*.js" --include="*.tsx" src/ lib/ app/ 2>/dev/null | grep -iE "release|environment"
  1. Check for deploy notification:
# Deploy finalization
grep -riE "sentry-cli.*releases.*finalize|sentry-cli.*releases.*deploys" .github/workflows/*.yml package.json 2>/dev/null
  1. Check how release is set:
# Release from git or env
grep -riE "release.*process\.env|release.*GIT|release.*COMMIT|release.*SHA|release.*VERSION" --include="*.ts" --include="*.js" src/ lib/ app/ config/ 2>/dev/null | head -5

If not found in code, ask user:

  • "Does Sentry know when deployments happen?"
  • "Can you filter Sentry errors by release version?"
  • "When a deploy goes out, can you see 'new errors in this release' in Sentry?"

Cross-reference with:

  • ERR-004 (source maps are tied to releases)
  • DEPLOY-004 (deployment tagging)

Pass criteria:

  • release set in Sentry.init (from git SHA, version, or env var)
  • Release created in Sentry during CI/CD (sentry-cli releases new)
  • Deploy notification sent (sentry-cli releases deploys new)
  • Can filter errors by release in Sentry dashboard

Fail criteria:

  • No release configured (all errors lumped together)
  • Release set but never created in Sentry (orphaned release)
  • No way to correlate errors with specific deployments

Partial (acceptable):

  • Release set but no deploy notification (you see releases but not deploy timestamps)
  • Release is git SHA only (works but less human-readable than semver)

Evidence to capture:

  • Release configuration method
  • CI/CD steps for release creation
  • Sample Sentry view showing release filtering

Section

19. Error Reporting

Error Tracking & Reliability