-
Notifications
You must be signed in to change notification settings - Fork 426
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(tracer): dd_trace_methods wrapping async functions #12337
Conversation
|
Datadog ReportBranch report: ✅ 0 Failed, 130 Passed, 1184 Skipped, 1m 35.03s Total Time |
releasenotes/notes/dd-trace-methods-wrapping-async-functions-efa8599ac82c45f2.yaml
Outdated
Show resolved
Hide resolved
BenchmarksBenchmark execution time: 2025-02-19 15:29:19 Comparing candidate commit 688bad4 in PR branch Found 0 performance improvements and 0 performance regressions! Performance is the same for 418 metrics, 2 unstable metrics. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
left some nits, as long as the tests pass this looks to me.
releasenotes/notes/dd-trace-methods-wrapping-async-functions-efa8599ac82c45f2.yaml
Outdated
Show resolved
Hide resolved
…fa8599ac82c45f2.yaml Co-authored-by: Munir Abdinur <[email protected]>
Resolves issue #10754
Updated
trace_wrapper
to check if the target function is async (usinginspect.iscoroutinefunction
). If it is, the wrapper uses async/await to keep the tracing span open until the coroutine truly finishes instead of closing immediately when the coroutine is created.Checklist
Reviewer Checklist