Repository navigation
sdk: percent-decode OTEL_RESOURCE_ATTRIBUTES keys as well as values - #5989
Open
WendeelMarinho wants to merge 2 commits into
Open
WendeelMarinho wants to merge 2 commits into
WendeelMarinho wants to merge 2 commits into
Conversation
Pull request dashboard statusWaiting on maintainers · refreshed 2026-12-02 15:56 UTC Merge when ready. Status above doesn't look right?
|
WendeelMarinho
force-pushed
the
fix/resource-attributes-decode-keys
branch
from
December 1, 2026 15:34
aee7e22 to
affa360
Compare
Contributor
|
I reviewed the changes in opentelemetry-sdk/src/opentelemetry/sdk/resources/init.py, opentelemetry-sdk/tests/resources/test_resources.py, and .changelog/5989.fixed. The fix cleanly resolves the specification gap in OTELResourceDetector.detect(). A few specific observations from inspecting the implementation and tests:
Solid fix. |
lzchen
approved these changes
Dec 2, 2026
4 tasks done
This branch has not been deployed
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.
The resource SDK spec says "The
,and=characters in keys and values MUST be percent encoded", butOTELResourceDetectoronly decodes the value, somy%2Ckey=vyields the keymy%2Ckey. This decodes the key the same way (#2847 did it for values).Type of change
Checklist:
tox -e precommit