From d0a8ff99cce530ff1bace59230167eb53748c1d1 Mon Sep 17 00:00:00 2001 From: Elias Ram Date: Tue, 11 Jun 2024 15:59:15 +0200 Subject: [PATCH] ref(metrics): Update type hints for tag values Remove None, Tuple, and List from the MetricTagValue type as these are not supported and might confuse the user --- sentry_sdk/_types.py | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/sentry_sdk/_types.py b/sentry_sdk/_types.py index 7ac85bad57..f86412602a 100644 --- a/sentry_sdk/_types.py +++ b/sentry_sdk/_types.py @@ -173,14 +173,7 @@ MetricTagsInternal = Tuple[Tuple[str, str], ...] # External representation of tags as a dictionary. - MetricTagValue = Union[ - str, - int, - float, - None, - List[Union[int, str, float, None]], - Tuple[Union[int, str, float, None], ...], - ] + MetricTagValue = Union[str, int, float] MetricTags = Mapping[str, MetricTagValue] # Value inside the generator for the metric value.