From f33e04eda44d7ca6d25097e91e75e436b54f4423 Mon Sep 17 00:00:00 2001 From: shimon-armis Date: Fri, 2 Sep 2022 09:37:10 +0300 Subject: [PATCH] prometheus_connect: Store "variance" operation result with the correct key Signed-off-by: shimon-armis --- prometheus_api_client/prometheus_connect.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/prometheus_api_client/prometheus_connect.py b/prometheus_api_client/prometheus_connect.py index b117d88..c09531c 100644 --- a/prometheus_api_client/prometheus_connect.py +++ b/prometheus_api_client/prometheus_connect.py @@ -485,7 +485,7 @@ def get_metric_aggregation( elif operation == "deviation": aggregated_values["deviation"] = numpy.std(np_array) elif operation == "variance": - aggregated_values["deviation"] = numpy.var(np_array) + aggregated_values["variance"] = numpy.var(np_array) else: raise TypeError("Invalid operation: " + operation) return aggregated_values