From bab7d57832dc9182635b4c6c5351b7b23ec1c918 Mon Sep 17 00:00:00 2001 From: Golovin Pavel Date: Fri, 31 Jan 2020 13:30:05 +0300 Subject: [PATCH] Add missing ABC for Metric Fix #390 --- opentelemetry-api/src/opentelemetry/metrics/__init__.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/opentelemetry-api/src/opentelemetry/metrics/__init__.py b/opentelemetry-api/src/opentelemetry/metrics/__init__.py index 947d57b976d..c6b339be13c 100644 --- a/opentelemetry-api/src/opentelemetry/metrics/__init__.py +++ b/opentelemetry-api/src/opentelemetry/metrics/__init__.py @@ -87,13 +87,14 @@ class DefaultLabelSet(LabelSet): """ -class Metric: +class Metric(abc.ABC): """Base class for various types of metrics. Metric class that inherit from this class are specialized with the type of handle that the metric holds. """ + @abc.abstractmethod def get_handle(self, label_set: LabelSet) -> "object": """Gets a handle, used for repeated-use of metrics instruments.