From cdd2d5c62787607969171ec131948b171951d73f Mon Sep 17 00:00:00 2001 From: Liudmila Molkova Date: Tue, 21 Jan 2025 19:53:48 -0800 Subject: [PATCH 1/4] Exclude attributes without stability from stable part --- .../opentelemetry/semconv/_incubating/metrics/hw_metrics.py | 2 +- .../opentelemetry/semconv/attributes/network_attributes.py | 5 ----- scripts/semconv/templates/registry/weaver.yaml | 2 +- 3 files changed, 2 insertions(+), 7 deletions(-) diff --git a/opentelemetry-semantic-conventions/src/opentelemetry/semconv/_incubating/metrics/hw_metrics.py b/opentelemetry-semantic-conventions/src/opentelemetry/semconv/_incubating/metrics/hw_metrics.py index 78199c68ad2..ca615236e7a 100644 --- a/opentelemetry-semantic-conventions/src/opentelemetry/semconv/_incubating/metrics/hw_metrics.py +++ b/opentelemetry-semantic-conventions/src/opentelemetry/semconv/_incubating/metrics/hw_metrics.py @@ -98,7 +98,7 @@ def create_hw_power( Operational status: `1` (true) or `0` (false) for each of the possible states Instrument: updowncounter Unit: 1 -Note: `hw.status` is currently specified as an *UpDownCounter* but would ideally be represented using a [*StateSet* as defined in OpenMetrics](https://github.com/prometheus/OpenMetrics/blob/v1.0.0/specification/OpenMetrics.md#stateset). This semantic convention will be updated once *StateSet* is specified in OpenTelemetry. This planned change is not expected to have any consequence on the way users query their timeseries backend to retrieve the values of `hw.status` over time. +Note: `hw.status` is currently specified as an *UpDownCounter* but would ideally be represented using a [*StateSet* as defined in OpenMetrics](https://github.com/OpenObservability/OpenMetrics/blob/main/specification/OpenMetrics.md#stateset). This semantic convention will be updated once *StateSet* is specified in OpenTelemetry. This planned change is not expected to have any consequence on the way users query their timeseries backend to retrieve the values of `hw.status` over time. """ diff --git a/opentelemetry-semantic-conventions/src/opentelemetry/semconv/attributes/network_attributes.py b/opentelemetry-semantic-conventions/src/opentelemetry/semconv/attributes/network_attributes.py index b585467bfb3..c09fe2e0c6f 100644 --- a/opentelemetry-semantic-conventions/src/opentelemetry/semconv/attributes/network_attributes.py +++ b/opentelemetry-semantic-conventions/src/opentelemetry/semconv/attributes/network_attributes.py @@ -15,11 +15,6 @@ from enum import Enum from typing import Final -NETWORK_INTERFACE_NAME: Final = "network.interface.name" -""" -The network interface name. -""" - NETWORK_LOCAL_ADDRESS: Final = "network.local.address" """ Local address of the network connection - IP address or Unix domain socket name. diff --git a/scripts/semconv/templates/registry/weaver.yaml b/scripts/semconv/templates/registry/weaver.yaml index fb6b7b1aa94..2fc03ef45aa 100644 --- a/scripts/semconv/templates/registry/weaver.yaml +++ b/scripts/semconv/templates/registry/weaver.yaml @@ -13,7 +13,7 @@ templates: filter: > semconv_grouped_attributes({ "exclude_root_namespace": $excluded_namespaces, - "exclude_stability": if $filter == "any" then [] else ["experimental"] end, + "exclude_stability": if $filter == "any" then [] else ["experimental", "", null] end, }) | map({ root_namespace: .root_namespace, From f63dd945a36172c46d4e2c2081172de607551cc5 Mon Sep 17 00:00:00 2001 From: Liudmila Molkova Date: Tue, 21 Jan 2025 20:03:49 -0800 Subject: [PATCH 2/4] changelog --- CHANGELOG.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 325b288ccfc..e42fac74dde 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ([#4371](https://github.com/open-telemetry/opentelemetry-python/pull/4371)) - Fix span context manager typing by using ParamSpec from typing_extensions ([#4389](https://github.com/open-telemetry/opentelemetry-python/pull/4389)) +- semantic-conventions: Remove `opentelemetry.semconv.attributes.network_attributes.NETWORK_INTERFACE_NAME` + introduced by mistake in wrong module. + ([#4391](https://github.com/open-telemetry/opentelemetry-python/pull/4391)) ## Version 1.29.0/0.50b0 (2024-12-11) From dfc317fc36127de7227de04d034d22ce2362bfac Mon Sep 17 00:00:00 2001 From: Liudmila Molkova Date: Wed, 22 Jan 2025 15:06:20 -0800 Subject: [PATCH 3/4] review --- CHANGELOG.md | 2 +- scripts/semconv/templates/registry/weaver.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e42fac74dde..92f6b9b9274 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,7 +18,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Fix span context manager typing by using ParamSpec from typing_extensions ([#4389](https://github.com/open-telemetry/opentelemetry-python/pull/4389)) - semantic-conventions: Remove `opentelemetry.semconv.attributes.network_attributes.NETWORK_INTERFACE_NAME` - introduced by mistake in wrong module. + introduced by mistake in the wrong module. ([#4391](https://github.com/open-telemetry/opentelemetry-python/pull/4391)) ## Version 1.29.0/0.50b0 (2024-12-11) diff --git a/scripts/semconv/templates/registry/weaver.yaml b/scripts/semconv/templates/registry/weaver.yaml index 2fc03ef45aa..42e41b9ecab 100644 --- a/scripts/semconv/templates/registry/weaver.yaml +++ b/scripts/semconv/templates/registry/weaver.yaml @@ -28,7 +28,7 @@ templates: filter: > semconv_grouped_metrics({ "exclude_root_namespace": $excluded_namespaces, - "exclude_stability": if $filter == "any" then [] else ["experimental"] end, + "exclude_stability": if $filter == "any" then [] else ["experimental", "", null] end, }) | map({ root_namespace: .root_namespace, From 4a6246847faf62638d1940b8379a5345dc2a02c8 Mon Sep 17 00:00:00 2001 From: Liudmila Molkova Date: Thu, 23 Jan 2025 08:29:41 -0800 Subject: [PATCH 4/4] Update CHANGELOG.md --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 92f6b9b9274..79b79455a7f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,7 +17,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ([#4371](https://github.com/open-telemetry/opentelemetry-python/pull/4371)) - Fix span context manager typing by using ParamSpec from typing_extensions ([#4389](https://github.com/open-telemetry/opentelemetry-python/pull/4389)) -- semantic-conventions: Remove `opentelemetry.semconv.attributes.network_attributes.NETWORK_INTERFACE_NAME` +- [BREAKING] semantic-conventions: Remove `opentelemetry.semconv.attributes.network_attributes.NETWORK_INTERFACE_NAME` introduced by mistake in the wrong module. ([#4391](https://github.com/open-telemetry/opentelemetry-python/pull/4391))