Repository navigation
feat(boto3): Add S3 extension - #7888
pabloDeputter wants to merge 25 commits into
Conversation
Codecov Results 📊✅ 55467 passed | ⏭️ 2750 skipped | Total: 58217 | Pass Rate: 95.28% | Execution Time: 155m 55s 📊 Comparison with Base Branch
All tests are passing successfully. ✅ Patch coverage is 100.00%. Project has 2054 uncovered lines. Coverage diff@@ Coverage Diff @@
## master #PR +/-##
==========================================
- Coverage 90.37% 90.09% -0.28%
==========================================
Files 202 187 -15
Lines 26547 20729 -5818
Branches 9852 7136 -2716
==========================================
+ Hits 23990 18675 -5315
- Misses 2557 2054 -503
- Partials 1496 1214 -282Generated by Codecov Action |
08ce57f to
c43fff1
Compare
ca494d2 to
9938a64
Compare
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 9eb12cd. Configure here.
| if "Delete" in ctx.params: | ||
| attributes[SPANDATA.AWS_S3_DELETE] = json.dumps( | ||
| ctx.params["Delete"], separators=(",", ":"), sort_keys=True | ||
| ) |
There was a problem hiding this comment.
Delete serialization drops S3 attributes
Low Severity
json.dumps of Delete cannot serialize timestamp values such as LastModifiedTime, a valid DeleteObjects field on directory buckets. That exception aborts get_request_attributes before it returns, so already-extracted attributes like aws.s3.bucket never reach the span.
Reviewed by Cursor Bugbot for commit 9eb12cd. Configure here.


Description
Adds the following request/response attributes:
aws.s3.bucket,aws.s3.key,aws.s3.upload_id,aws.s3.copy_source,aws.s3.delete,aws.s3.part_number,http.response.body.size(number of bytes in payload),file.size(represents the total file/object size)Following tests were removed/moved from old
test_s3.py(old boto3 integration only added s3 streaming responses support):test_basic()removed - basically only tests botocore xml parsing behavior; generic span behavior is already tested intest_client.py.test_streaming()/test_streaming_close()removed - behavior is already tested intest_client.pywith mock HTTP server.test_span_origin()removed - overlaps with existing tests.test_omit_url_data_if_parsing_fails()moved totest_client.pyand simplified since it's generic instrumentation.test_breadcrumb()andtest_url_query_data_collection_breadcrumb()moved and combined totest_client.py, once again since it's generic instrumentation.Issues
Resolves #7576