refactor(tracer): use Context instead of SpanContext#853
Open
pvital wants to merge 5 commits intoinstana:mainfrom
Open
refactor(tracer): use Context instead of SpanContext#853pvital wants to merge 5 commits intoinstana:mainfrom
pvital wants to merge 5 commits intoinstana:mainfrom
Conversation
To maintain OpenTelemetry API compliance, this commit changes the InstanaTracer to use OTel's `Context` instead of the Instana's `SpanContext` as `context` parameter for `start_as_current_span()` and `start_span()`. methods. This commit fixes instana#847. Signed-off-by: Paulo Vital <paulo.vital@ibm.com> Co-authored-by: Varsha GS <varsha.gs@ibm.com>
This was referenced Mar 20, 2026
This commit updates base_propagator to use the `context` parameter instead of the deprecated `span_context` parameter when calling `start_span()` and `start_as_current_span()` methods. This change aligns with OpenTelemetry's API conventions and improves consistency across the codebase. This commit fixes instana#847. Signed-off-by: Paulo Vital <paulo.vital@ibm.com> Co-authored-by: Varsha GS <varsha.gs@ibm.com>
This commit updates all instrumentation modules to use the `context` parameter instead of the deprecated `span_context` parameter when calling `start_span()` and `start_as_current_span()` methods. This change aligns with OpenTelemetry's API conventions and improves consistency across the codebase. This commit fixes instana#847. Signed-off-by: Paulo Vital <paulo.vital@ibm.com> Co-authored-by: Varsha GS <varsha.gs@ibm.com>
This commit updates all tests to use the `context` parameter instead of the deprecated `span_context` parameter when calling `start_span()` and `start_as_current_span()` methods. This commit fixes instana#847. Signed-off-by: Paulo Vital <paulo.vital@ibm.com> Co-authored-by: Varsha GS <varsha.gs@ibm.com>
Added type annotations to the binary, HTTP and text propagators and used ruff (vscode) to: - Black-compatible code formatting. - fix all auto-fixable violations, like unused imports. - isort-compatible import sorting. Signed-off-by: Paulo Vital <paulo.vital@ibm.com>
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.
To maintain OpenTelemetry API compliance, this PR contains multiple commits that change multiple parts of the code to use the
contextparameter instead of the deprecatedspan_contextparameter when callingstart_span()andstart_as_current_span()methods.These changes align with OpenTelemetry's API conventions and improve consistency across the codebase.
This PR consists of the following commits:
Contextinstead of Instana'sSpanContextascontextparameter forstart_as_current_span()andstart_span(). methods.contextparameter instead of the deprecatedspan_contextparameter when callingstart_span()andstart_as_current_span()methods.contextparameter instead of the deprecated
span_contextparameter when callingstart_span()andstart_as_current_span()methods.This PR fixes #847.