Skip to content

Strip only the leading uberctx- prefix from a Jaeger baggage key - #5557

Open
serhiy-bzhezytskyy wants to merge 2 commits into
open-telemetry:mainfrom
serhiy-bzhezytskyy:fix/jaeger-baggage-key-prefix
Open

Strip only the leading uberctx- prefix from a Jaeger baggage key#5557
serhiy-bzhezytskyy wants to merge 2 commits into
open-telemetry:mainfrom
serhiy-bzhezytskyy:fix/jaeger-baggage-key-prefix

Conversation

@serhiy-bzhezytskyy

Copy link
Copy Markdown

JaegerPropagator._extract_baggage builds the baggage key with key.replace(self.BAGGAGE_PREFIX, ""), which
removes every occurrence of uberctx- rather than the leading one. A carrier key that repeats the prefix loses the
inner literal: uberctx-a-uberctx-b extracts as the baggage key a-b instead of a-uberctx-b. Slicing the prefix
off fixes it.

Adds one test that fails on main with a-b. The test class needs pylint's max-public-methods relaxed for the
added method, the same way propagator/opentelemetry-propagator-b3/tests/test_b3_format.py does.

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

`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
@serhiy-bzhezytskyy
serhiy-bzhezytskyy requested a review from a team as a code owner August 19, 2026 04:21
@opentelemetry-pr-dashboard

opentelemetry-pr-dashboard Bot commented Aug 19, 2026

Copy link
Copy Markdown

Pull request dashboard status

Waiting on reviewers · refreshed 2026-08-21 01:46 UTC

Review the latest changes.

Status above doesn't look right?
  • Just replied or pushed? Anything around or after the refresh time above may not be picked up yet — give it a few minutes.
  • Anything look wrong? Report it with what you expected; it helps us improve the dashboard.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

1 participant