refactor(cli): localize SDK tracing#33273
Conversation
75b4bb4 to
2e0aee9
Compare
|
@mergify update |
✅ Branch has been successfully updated |
Codecov ReportAttention: Patch coverage is
❌ Your patch status has failed because the patch coverage (68.29%) is below the target coverage (95.00%). You can increase the patch coverage or adjust the target coverage. Additional details and impacted files@@ Coverage Diff @@
## main #33273 +/- ##
==========================================
- Coverage 80.84% 80.80% -0.04%
==========================================
Files 236 236
Lines 14230 14235 +5
Branches 2487 2487
==========================================
- Hits 11504 11503 -1
- Misses 2442 2448 +6
Partials 284 284
Flags with carried forward coverage won't be shown. Click here to find out more.
|
|
➡️ PR build request submitted to A maintainer must now check the pipeline and add the |
| * role doesn't have `sts:AssumeRole` and will fail for no real good reason. | ||
| */ | ||
| @traceMethods | ||
| @traceMemberMethods |
There was a problem hiding this comment.
i did not know we had these decorators...
| logger[meth]('test'); | ||
| expect(trace).not.toHaveBeenCalled(); | ||
| test.each(['trace', 'debug'] as Array<keyof SdkToCliLogger>)('%s method does not call notify', (method) => { | ||
| logger[method]('test'); |
✅ Updated pull request passes all PRLinter validations. Dismissing previous PRLinter review.
|
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
|
This pull request has been removed from the queue for the following reason: The merge conditions cannot be satisfied due to failing checks:
You should look at the reason for the failure and decide if the pull request needs to be fixed or if you want to requeue it. If you want to requeue this pull request, you need to post a comment with the text: |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
|
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
|
Comments on closed issues and PRs are hard for our team to see. |
Reason for this change
The CLI has a global method call tracing feature that is currently only used for SDK calls.
Eventually this feature needs to support logging through the IoHost. While this PR doesn't achieve this, it co-locates the tracing feature with SDK logs and explicitly calls out its limitations.
We will need a better, different approach once we are looking at the SDK Provider in more detail.
Description of changes
Move the feature to
aws-authmodule.Limit exports and renames for clarity.
Limit tracing to member methods as these can add a class logger.
Add a manual trace to the one static method this was currently tracig
Describe any new or updated permissions being added
n/a
Description of how you validated changes
Existing unit & integ tests, manual verification
Checklist
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license