When using the sentry-tower/axum integration with streaming responses, the middleware binds the hub only for the request handler. Once the handler returns a streaming body, the middleware unwinds and axum drains the stream outside that hub. This causes missing context and any newly set context to be attached to the wrong hub during stream evaluation.
Track the tracing/transaction behavior separately in #1053.
A possible direction is to bind the hub to the response stream, similar to getsentry/objectstore#526.
When using the
sentry-tower/axumintegration with streaming responses, the middleware binds the hub only for the request handler. Once the handler returns a streaming body, the middleware unwinds andaxumdrains the stream outside that hub. This causes missing context and any newly set context to be attached to the wrong hub during stream evaluation.Track the tracing/transaction behavior separately in #1053.
A possible direction is to bind the hub to the response stream, similar to getsentry/objectstore#526.