Fix ExpandedValue sanitization on struct collection by theomagellan · Pull Request #14413 · open-telemetry/opentelemetry-collector (original) (raw)

and others added 2 commits

January 8, 2026 18:07

@theomagellan

… unmarshalling a confmap

useExpandedValue would resolve ExpandedValues after checking if a collection's type was "stringy." For collections of structs, isStringy always returns false, causing all ExpandedValues to be sanitized to their parsed values and breaking decoding of string fields if the parsed value was not string.

Now, useExpandedValue checks if it's dealing with a collection of structs; in which case, skip sanitization and rely on mapstructure's per-field decoding.

@theomagellan

@theomagellan

@theomagellan

theomagellan

theomagellan

@theomagellan

jade-guiton-dd

theomagellan

@theomagellan

@theomagellan

The e2e test module was not recording coverage for the parent confmap/internal package that it tests. This caused test coverage to appear as 0% even though the tests exercise the code.

This adds the parent package to COVER_PKGS so coverage of confmap/internal is properly tracked for e2e tests.

theomagellan

@theomagellan

@mx-psi

mx-psi

mx-psi

@theomagellan @mx-psi

Co-authored-by: Pablo Baeyens pbaeyens31+github@gmail.com

@theomagellan

jade-guiton-dd

@theomagellan

Merged via the queue into open-telemetry:main with commit 246e428

Jan 20, 2026

60 of 61 checks passed

github-merge-queue Bot pushed a commit that referenced this pull request

Jan 21, 2026

@theomagellan

Description

The e2e test module was not recording coverage for the parent confmap/internal package that it tests. This caused test coverage to appear as 0% even though the tests exercise the code.

This adds the parent package to COVER_PKGS so coverage of confmap/internal is properly tracked for e2e tests. When looking at overall coverage of confmap/internal/decoder.go, it goes from 91.4% to 96.3% of statements.

Issue was found in PR #14413 (review).

Testing

Running make gotest-with-cover without the fix, then looking at coverage in percentage with

go tool covdata percent -i=./coverage/unit -pkg=go.opentelemetry.io/collector/confmap/internal

Running these commands again with the fix added shows the improvement.

The e2e tests can also be run individually to verify they're tracking parent package coverage:

make -C confmap/internal/e2e test-with-cover
# [...] coverage: 45.3% of statements in go.opentelemetry.io/collector/confmap/internal, go.opentelemetry.io/collector/confmap/internal/e2e, )

TimoBehrendt pushed a commit to TimoBehrendt/tracebasedlogsampler that referenced this pull request

Mar 19, 2026

…ocessortest to v0.147.0 (#38)

This PR contains the following updates:

Package Change Age Confidence
go.opentelemetry.io/collector/processor/processortest v0.144.0v0.147.0 age confidence

Release Notes

open-telemetry/opentelemetry-collector (go.opentelemetry.io/collector/processor/processortest)

v0.147.0

Compare Source

💡 Enhancements 💡
🧰 Bug fixes 🧰

v0.146.1

Compare Source

v0.146.0

Compare Source

🛑 Breaking changes 🛑
🚩 Deprecations 🚩
💡 Enhancements 💡
🧰 Bug fixes 🧰

v0.145.0

Compare Source

💡 Enhancements 💡
🧰 Bug fixes 🧰

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.



This PR has been generated by Renovate Bot.

Reviewed-on: https://gitea.t000-n.de/t.behrendt/tracebasedlogsampler/pulls/38 Reviewed-by: t.behrendt t.behrendt@noreply.localhost Co-authored-by: Renovate Bot renovate@t00n.de Co-committed-by: Renovate Bot renovate@t00n.de

TimoBehrendt pushed a commit to TimoBehrendt/tracebasedlogsampler that referenced this pull request

Mar 26, 2026

…1.54.0 (#33)

This PR contains the following updates:

Package Change Age Confidence
go.opentelemetry.io/collector/confmap v1.50.0v1.54.0 age confidence

Release Notes

open-telemetry/opentelemetry-collector (go.opentelemetry.io/collector/confmap)

v1.54.0

❗ Known Issues ❗
🛑 Breaking changes 🛑
💡 Enhancements 💡
🧰 Bug fixes 🧰

v1.53.0

💡 Enhancements 💡
🧰 Bug fixes 🧰

v1.52.0

v1.51.0

💡 Enhancements 💡
🧰 Bug fixes 🧰

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.



This PR has been generated by Renovate Bot.

Reviewed-on: https://gitea.t000-n.de/t.behrendt/tracebasedlogsampler/pulls/33 Reviewed-by: t.behrendt t.behrendt@noreply.localhost Co-authored-by: Renovate Bot renovate@t00n.de Co-committed-by: Renovate Bot renovate@t00n.de

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

[ Show hidden characters]({{ revealButtonHref }})