diff --git a/src/Storage/RedisStorage/HistogramRedisStorage.php b/src/Storage/RedisStorage/HistogramRedisStorage.php index 28d197e..a7371c8 100644 --- a/src/Storage/RedisStorage/HistogramRedisStorage.php +++ b/src/Storage/RedisStorage/HistogramRedisStorage.php @@ -111,7 +111,14 @@ public function fetchHistograms(): iterable ); } - Assert::notEmpty($bucketsWithValues); + Assert::notEmpty( + $bucketsWithValues, + sprintf( + 'Buckets with values are empty for [%s] metric with key [%s]', + $keyWithLabels->metricName, + $this->metricKeySerializer->serialize($keyWithLabels), + ) + ); $bucketsWithValues = array_map('floatval', $bucketsWithValues); yield new HistogramMetricValue(