Skip to content

Support OTEL_PYTHON_* extensions when OTEL_CONFIG_FILE is set - #5699

Open
GauravR31 wants to merge 6 commits into
open-telemetry:mainfrom
GauravR31:issue-5352
Open

GauravR31 wants to merge 6 commits into
open-telemetry:mainfrom
GauravR31:issue-5352

Conversation

@GauravR31

@GauravR31 GauravR31 commented Sep 26, 2026 •

Copy link
Copy Markdown
Contributor

Description

Previously, when OTEL_CONFIG_FILE was set, every OTEL_PYTHON* implementation extension (e.g. OTEL_PYTHON_LOGGING_AUTO_INSTRUMENTATION_ENABLED, OTEL_PYTHON_TRACER_CONFIGURATOR) was silently bypassed. This PR adds functionality to honour these extensions as environment variables even when the declarative configuration is set.

Fixes #5352

Type of change

Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)
  • This change requires a documentation update

How Has This Been Tested?

All existing tests pass. Added the following new tests:

  • test_python_extensions_run_after_declarative_configuration
  • test_python_configurators_are_applied_to_configured_global_providers
  • test_python_configurators_are_not_applied_when_provider_sections_are_omitted
  • test_python_configurators_are_not_applied_when_config_is_disabled

Does This PR Require a Contrib Repo Change?

  • Yes. - Link to PR:
  • No.

Checklist:

  • Followed the style guidelines of this project
  • Changelogs have been updated
  • Unit tests have been added
  • Documentation has been updated

@GauravR31
GauravR31 requested a review from a team as a code owner September 26, 2026 19:33
@opentelemetry-pr-dashboard

opentelemetry-pr-dashboard Bot commented Sep 26, 2026 •

Copy link
Copy Markdown

Pull request dashboard status

Waiting on reviewers · refreshed 2026-09-26 19:54 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.

This branch has not been deployed

No deployments
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.

feat(config): honour OTEL_PYTHON_* extensions when OTEL_CONFIG_FILE is set

1 participant