From 5d7f007feed8b61338196c1ba951bf4594cb2981 Mon Sep 17 00:00:00 2001 From: Chris Kleinknecht Date: Sat, 14 Mar 2020 14:29:08 -0700 Subject: [PATCH 1/2] Fix versionchanged doc from #466 --- opentelemetry-api/src/opentelemetry/trace/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/opentelemetry-api/src/opentelemetry/trace/__init__.py b/opentelemetry-api/src/opentelemetry/trace/__init__.py index e23404f707b..42133c6c511 100644 --- a/opentelemetry-api/src/opentelemetry/trace/__init__.py +++ b/opentelemetry-api/src/opentelemetry/trace/__init__.py @@ -62,8 +62,8 @@ .. versionadded:: 0.1.0 .. versionchanged:: 0.3.0 - `TracerProvider` was introduced and the global ``tracer`` getter was replaced - by `get_tracer_provider`. + `TracerProvider` was introduced and the global ``tracer`` getter was + replaced by `tracer_provider`. """ import abc From c2feaf1de2048228890b6151f02c4dfc1ec52ff4 Mon Sep 17 00:00:00 2001 From: Chris Kleinknecht Date: Sat, 14 Mar 2020 15:21:30 -0700 Subject: [PATCH 2/2] Add note about get_tracer_provider and add similar docs for metrics. --- opentelemetry-api/src/opentelemetry/metrics/__init__.py | 6 +++++- opentelemetry-api/src/opentelemetry/trace/__init__.py | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/opentelemetry-api/src/opentelemetry/metrics/__init__.py b/opentelemetry-api/src/opentelemetry/metrics/__init__.py index c37119529b6..82545942821 100644 --- a/opentelemetry-api/src/opentelemetry/metrics/__init__.py +++ b/opentelemetry-api/src/opentelemetry/metrics/__init__.py @@ -24,7 +24,11 @@ .. _metrics api: https://github.com/open-telemetry/opentelemetry-specification/blob/master/specification/api-metrics.md - +.. versionadded:: 0.1.0 +.. versionchanged:: 0.5.0 + ``meter_provider`` was replaced by `get_meter_provider`, + ``set_preferred_meter_provider_implementation`` was replaced by + `set_meter_provider`. """ import abc from logging import getLogger diff --git a/opentelemetry-api/src/opentelemetry/trace/__init__.py b/opentelemetry-api/src/opentelemetry/trace/__init__.py index 42133c6c511..69cca344b6a 100644 --- a/opentelemetry-api/src/opentelemetry/trace/__init__.py +++ b/opentelemetry-api/src/opentelemetry/trace/__init__.py @@ -63,7 +63,11 @@ .. versionadded:: 0.1.0 .. versionchanged:: 0.3.0 `TracerProvider` was introduced and the global ``tracer`` getter was - replaced by `tracer_provider`. + replaced by ``tracer_provider``. +.. versionchanged:: 0.5.0 + ``tracer_provider`` was replaced by `get_tracer_provider`, + ``set_preferred_tracer_provider_implementation`` was replaced by + `set_tracer_provider`. """ import abc