-
Notifications
You must be signed in to change notification settings - Fork 5
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
feat: instrument pyo3-opentelemetry #391
Merged
Merged
Conversation
This file contains 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
erichulburd
force-pushed
the
instrument_otel
branch
3 times, most recently
from
November 15, 2023 23:17
9185912
to
fe7f686
Compare
MarquessV
reviewed
Nov 20, 2023
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.
Thanks for doing this! A couple of comments, but mostly looks like issues with the type hints.
Oh - when testing I also noticed that |
erichulburd
force-pushed
the
instrument_otel
branch
from
December 19, 2023 01:32
cfb5827
to
981544f
Compare
MarquessV
approved these changes
Dec 19, 2023
@erichulburd The checks are passing on this PR now. Would you like me to rebase, merge, and release an RC? |
erichulburd
force-pushed
the
instrument_otel
branch
from
January 17, 2024 21:39
dea3e23
to
2e9118f
Compare
MarquessV
added a commit
that referenced
this pull request
Jan 26, 2024
This reverts commit 1cf88e9.
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.
Goals
The goal of this MR is to support collection of Rust traces by Python end users. Specifically this entails:
Design & Implementation
pyo3_opentelemetry::pypropagate
macro will get the OpenTelemetry context from Python, deserialize it, and set it as the current context on the Rust side. This ensures traces initialized on the Python side are connected to traces within Rust.tracing_subscriber
module frompyo3-tracing-subscriber
(see crates/python/src/lib.rs::qcs_sdk). We also autogenerate stubs for this Python module in crates/python/build.rs (stub files are formatted withcargo make format-tracing-subscriber
).