Skip to content

We are seeing panics in 0.39.0Β #1146

@dontlaugh

Description

@dontlaugh

Go version 1.25.1

Sentry SDK version: 0.39.0

This doesn't show exactly what's wrong, but this is how we're logging currently.

		defer func() {
			if r := recover(); r != nil {
				logrus.WithField("panic", r).Warn("panic recovered while sending to Sentry")
			}
		}()

		fields := entry.Data
		if fields != nil && fields["dd.trace_id"] != nil {
			fields["trace_url"] = fmt.Sprintf("https://us5.datadoghq.com/apm/trace/%d", fields["dd.trace_id"])
		}
		sentry.WithScope(func(scope *sentry.Scope) {
			scope.SetContext("additional_fields", fields)
			sentry.CaptureException(err)
		})

We're seeing panics from sentry-go tracing code, and it seems recent.

Given the snippet above, what we think is happening is we're passing in a custom error type (or perhaps something in the fields map) and one of those objects causes a panic in json serialization.

Looking at the changes in 0.39.0, the only other idea I have at the moment is a possibly nil transport.

Metadata

Metadata

Assignees

Labels

BugIssue type

Projects

Status

Waiting for: Product Owner

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions