0.20.0
The Sentry SDK team is happy to announce the immediate availability of Sentry Go SDK v0.20.0.
Note: this release has some breaking changes, which are listed below.
Breaking Changes
-
Remove the following methods:
Scope.SetTransaction(),Scope.Transaction()(#605)Span.Name should be used instead to access the transaction's name.
For example, the following
TracesSamplerfunction should be now written as follows:Before:
TracesSampler: func(ctx sentry.SamplingContext) float64 { hub := sentry.GetHubFromContext(ctx.Span.Context()) if hub.Scope().Transaction() == "GET /health" { return 0 } return 1 },
After:
TracesSampler: func(ctx sentry.SamplingContext) float64 { if ctx.Span.Name == "GET /health" { return 0 } return 1 },
Features
- Add
Span.SetContext()method (#599)- It is recommended to use it instead of
hub.Scope().SetContextwhen setting or updating context on transactions.
- It is recommended to use it instead of
- Add
DebugMetainterface toEventand extendFramestructure with more fields (#606)- More about DebugMeta interface here.
Bug Fixes
- [otel] Fix missing OpenTelemetry context on some events (#599, #605)
- Fixes (#596).
- [otel] Better handling for HTTP span attributes (#610)
Misc
- Bump minimum versions:
github.com/kataras/iris/v12to 12.2.0,github.com/labstack/echo/v4to v4.10.0 (#595) - Bump
google.golang.org/protobufminimum required version to 1.29.1 (#604)- This fixes a potential denial of service issue (CVE-2023-24535).
- Exclude the
otelmodule when building in GOPATH mode (#615)