fix(boto3): Fix botocore SigV4 failures caused by post-sign trace propagation - #7050
Draft
pabloDeputter wants to merge 2 commits into
Draft
fix(boto3): Fix botocore SigV4 failures caused by post-sign trace propagation#7050pabloDeputter wants to merge 2 commits into
pabloDeputter wants to merge 2 commits into
Conversation
- merge Sentry baggage with existing vendor (e.g. Datadog) baggage in botocore's`before-sign` hook; avoiding post-sign header tampering that invalidates the SigV4 signature. - Skip propagation for presigned requests Fixes: #7031 & PY-2667
Contributor
Codecov Results 📊✅ 96711 passed | ❌ 1 failed | ⏭️ 6191 skipped | Total: 102903 | Pass Rate: 93.98% | Execution Time: 348m 30s 📊 Comparison with Base Branch
➕ New Tests (1)View new tests
❌ Failed Tests
|
| File | Patch % | Lines |
|---|---|---|
| sentry_sdk/integrations/stdlib.py | 80.00% | |
| sentry_sdk/integrations/boto3.py | 84.62% |
Coverage diff
@@ Coverage Diff @@
## main #PR +/-##
==========================================
+ Coverage 89.90% 89.91% +0.01%
==========================================
Files 193 193 —
Lines 24822 24896 +74
Branches 8924 8958 +34
==========================================
+ Hits 22315 22383 +68
- Misses 2507 2513 +6
- Partials 1417 1423 +6Generated by Codecov Action
- trace-header injection is delayed until `endheaders()` after all request headers are available. - avoid duplicate propagation headers. - no tampering/modifying of already signed baggage Fixes: #7031 & PY-2667
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.
WIP!
Description
before-signhook; avoiding post-sign header tampering that invalidates the SigV4 signature.Issues
Resolves: #7031 & PY-2667
Reminders
uv run ruff.feat:,fix:,ref:,meta:)