From 72fe170dc81c0ff38a48a8a607345a2a321e6fc3 Mon Sep 17 00:00:00 2001 From: "J. Nick Koston" Date: Thu, 29 Feb 2024 16:23:33 -1000 Subject: [PATCH] Remove unused variable in stats _sorted_statistics_to_dict (#111912) --- homeassistant/components/recorder/statistics.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/homeassistant/components/recorder/statistics.py b/homeassistant/components/recorder/statistics.py index 5abe395a8d7..771d85e3569 100644 --- a/homeassistant/components/recorder/statistics.py +++ b/homeassistant/components/recorder/statistics.py @@ -2056,7 +2056,7 @@ def _sorted_statistics_to_dict( # noqa: C901 seen_statistic_ids: set[str] = set() key_func = itemgetter(metadata_id_idx) for meta_id, group in groupby(stats, key_func): - stats_list = stats_by_meta_id[meta_id] = list(group) + stats_by_meta_id[meta_id] = list(group) seen_statistic_ids.add(metadata[meta_id]["statistic_id"]) # Set all statistic IDs to empty lists in result set to maintain the order