diff --git a/config/sentry.go b/config/sentry.go index 3068bfa..f176e03 100644 --- a/config/sentry.go +++ b/config/sentry.go @@ -113,8 +113,7 @@ func initSentry(config sentryConfig, debug bool) { AttachStacktrace: true, EnableTracing: config.EnableTracing, TracesSampler: func(ctx sentry.SamplingContext) float64 { - hub := sentry.GetHubFromContext(ctx.Span.Context()) - txName := hub.Scope().Transaction() + txName := ctx.Span.Name for _, ex := range excludedRoutes { if strings.HasPrefix(txName, ex) { return 0.0 diff --git a/go.mod b/go.mod index 345a1c9..a1b52f9 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/emersion/go-sasl v0.0.0-20220912192320-0145f2c60ead github.com/emersion/go-smtp v0.17.0 github.com/emvi/logbuch v1.2.0 - github.com/getsentry/sentry-go v0.17.0 + github.com/getsentry/sentry-go v0.22.0 github.com/glebarez/sqlite v1.8.0 github.com/go-chi/chi/v5 v5.0.8 github.com/gorilla/schema v1.2.0