Skip to content

tracing: log v2-enabled message at info level#715

Merged
jon-whit merged 1 commit into
masterfrom
tracing/v2-enabled-info-log
May 28, 2026
Merged

tracing: log v2-enabled message at info level#715
jon-whit merged 1 commit into
masterfrom
tracing/v2-enabled-info-log

Conversation

@jon-whit
Copy link
Copy Markdown
Contributor

@jon-whit jon-whit commented May 28, 2026

The "v2 tracing is enabled; skipping v0 tracer configuration" message was emitted through cfg.Logger - if a client sets their configured log level to ERROR then this logs at error level. This is purely informational - it shouldn't be logged at the log level set on the logger. It should always be logged as an info level log. It is also logged before the logger is constructed - so it ought to use the default global logger at this point in the constructor.

This fixes the log level so that clients using this API surface don't get spammy error logs.

✅ Checks

  • CI tests (if present) are passing
  • Adheres to code style for repo
  • Contributor License Agreement (CLA) completed if not a Reddit employee

The "v2 tracing is enabled; skipping v0 tracer configuration" message
was emitted through cfg.Logger, a log.Wrapper. Wrapper is documented
for unexpected/recoverable errors and defaults to ErrorWithSentryWrapper,
so this informational message was being logged at ERROR level and
captured by Sentry. Switch to log.Info so it respects the global
logger's level (suppressed when configured at ERROR) and never reaches
Sentry.
@jon-whit jon-whit requested a review from a team as a code owner May 28, 2026 21:55
@jon-whit jon-whit requested review from konradreiche, mathyourlife-reddit, pacejackson and will-meng and removed request for a team May 28, 2026 21:55
@jon-whit jon-whit merged commit c8af3e9 into master May 28, 2026
2 checks passed
@jon-whit jon-whit deleted the tracing/v2-enabled-info-log branch May 28, 2026 22:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants