Skip to content

fix(telemetry): silence ConfigError for missing DSN - #1431

Open
sentry[bot] wants to merge 1 commit into
mainfrom
seer/fix/telemetry-silence-configerror
Open

fix(telemetry): silence ConfigError for missing DSN#1431
sentry[bot] wants to merge 1 commit into
mainfrom
seer/fix/telemetry-silence-configerror

Conversation

@sentry

@sentry sentry Bot commented Aug 15, 2026

Copy link
Copy Markdown
Contributor

This PR silences ConfigError in the CLI's error-reporting layer. Previously, ConfigErrors, primarily triggered by AI agents (like Codex) attempting to use sentry send-event without a DSN configured, were being reported to Sentry telemetry as issues.

Root Cause (CLI-28M): ConfigError indicates a user misconfiguration (no DSN provided via --dsn flag or SENTRY_DSN environment variable). This is an expected and handled error condition, not a bug in the CLI itself. However, it was not explicitly listed in the classifySilenced() function, leading to unnecessary noise in telemetry.

Solution:

  1. Added ConfigError to the SilenceReason type.
  2. Imported ConfigError into packages/cli/src/lib/error-reporting.ts.
  3. Modified classifySilenced() to return 'config_error' when an instanceof ConfigError is encountered. This ensures these expected user-misconfiguration errors are no longer reported as Sentry issues, while still being tracked by the cli.error.silenced metric.
  4. Updated the corresponding test in packages/cli/test/lib/error-reporting.test.ts to reflect this change, moving ConfigError from the 'does NOT silence' group to a dedicated test asserting it is now silenced as 'config_error'.

Fixes CLI-28M

This PR was automatically generated by Sentry. You can adjust this setting at any time.

@vercel

vercel Bot commented Aug 15, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
cli Ready Ready Preview Aug 15, 2026 10:49am

Request Review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk: low PR risk score: low

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants