Strip only the leading uberctx- prefix from a Jaeger baggage key - #5557
Open
serhiy-bzhezytskyy wants to merge 2 commits into
Open
Strip only the leading uberctx- prefix from a Jaeger baggage key#5557serhiy-bzhezytskyy wants to merge 2 commits into
serhiy-bzhezytskyy wants to merge 2 commits into
Conversation
`key.replace(self.BAGGAGE_PREFIX, "")` removes every occurrence, so a carrier key that repeats the prefix loses the inner literal: `uberctx-a-uberctx-b` became the baggage key `a-b` instead of `a-uberctx-b`. Slice off the prefix instead. The class needs pylint's max-public-methods relaxed for the added test, the same way `propagator/opentelemetry-propagator-b3/tests/test_b3_format.py` does. Assisted-By: Claude Fable 5
Assisted-By: Claude Fable 5
Pull request dashboard statusWaiting on reviewers · refreshed 2026-08-21 01:46 UTC Review the latest changes. Status above doesn't look right?
|
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.
JaegerPropagator._extract_baggagebuilds the baggage key withkey.replace(self.BAGGAGE_PREFIX, ""), whichremoves every occurrence of
uberctx-rather than the leading one. A carrier key that repeats the prefix loses theinner literal:
uberctx-a-uberctx-bextracts as the baggage keya-binstead ofa-uberctx-b. Slicing the prefixoff fixes it.
Adds one test that fails on
mainwitha-b. The test class needs pylint'smax-public-methodsrelaxed for theadded method, the same way
propagator/opentelemetry-propagator-b3/tests/test_b3_format.pydoes.This touches the same method as #5556, two lines from the byte accounting there, so whichever merges second needs a
trivial rebase.
Assisted-By: Claude Fable 5