test(flask): Add span streaming test coverage#6264
Merged
Conversation
Add request body data to the streaming segment span when span streaming is enabled. Update existing tests to cover both streaming and non-streaming code paths, and add new tests for request body capture, size limits, and header scrubbing in streaming mode. Fixes PY-2323 Fixes #6021
Member
Author
|
bugbot run |
Member
Author
|
@sentry review |
Contributor
Codecov Results 📊✅ 282 passed | Total: 282 | Pass Rate: 100% | Execution Time: 42.54s All tests are passing successfully. ❌ Patch coverage is 0.00%. Project has 14867 uncovered lines. Files with missing lines (1)
Generated by Codecov Action |
ericapisani
commented
May 14, 2026
alexander-alderman-webb
requested changes
May 15, 2026
Contributor
alexander-alderman-webb
left a comment
There was a problem hiding this comment.
I just looked at the request body attribute since I'm solving this in Starlette right now, and the same problem applies here 😅
… of just as the request is getting started
Member
Author
|
bugbot run |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit b7c0ec6. Configure here.
…hich we are no longer doing. Add test coverage to ensure span streaming is working as expected
alexander-alderman-webb
approved these changes
May 19, 2026
Contributor
|
The tests seem to fail; feel free to merge after fixing them if it's a trivial problem. |
…duction it would be set
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add test coverage to ensure that span streaming works for Flask. No additional changes are needed because we are no longer adding the request body to the streamed spans, and span streaming support has been added earlier to the uWSGI middleware which the Flask integration leverages.
Fixes PY-2323
Fixes #6021