SIGN IN SIGN UP

opentelemetry-instrumentation-logging: don't add out of spec attributes by default (#4112)

* opentelemetry-instrumentation-logging: don't add out of spec attributes by default

Add span context attributes to logging module LogRecord only if the instrumentation
has been configured to do so via set_logging_format argument or OTEL_PYTHON_LOG_CORRELATION
environment variable.

* Add changelog

* Update doc and cleanup tests

* Reduce diff

* Add missing test
R
Riccardo Magliocchetti committed
277b1a7b1ca1f0830299bd1548a0448cda6288c4
Parent: 95b52b5
Committed by GitHub <noreply@github.com> on 1/23/2026, 2:44:24 PM