From 347193055e2d78716a6fc8b45d3e776a7b1d7c81 Mon Sep 17 00:00:00 2001 From: Erik Montnemery Date: Mon, 9 May 2022 22:10:26 +0200 Subject: [PATCH] Rename logbook humanify function (#71597) Co-authored-by: J. Nick Koston --- homeassistant/components/logbook/__init__.py | 4 ++-- tests/components/logbook/common.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/homeassistant/components/logbook/__init__.py b/homeassistant/components/logbook/__init__.py index 5ec03b3aaa4..d3ede5303fb 100644 --- a/homeassistant/components/logbook/__init__.py +++ b/homeassistant/components/logbook/__init__.py @@ -324,7 +324,7 @@ class LogbookView(HomeAssistantView): ) -def humanify( +def _humanify( hass: HomeAssistant, rows: Generator[Row, None, None], entity_name_cache: EntityNameCache, @@ -548,7 +548,7 @@ def _get_events( query = query.order_by(Events.time_fired) return list( - humanify( + _humanify( hass, yield_rows(query), entity_name_cache, diff --git a/tests/components/logbook/common.py b/tests/components/logbook/common.py index c5b8c8239e1..896add3104e 100644 --- a/tests/components/logbook/common.py +++ b/tests/components/logbook/common.py @@ -52,7 +52,7 @@ def mock_humanify(hass_, rows): context_lookup, entity_name_cache, {}, event_cache ) return list( - logbook.humanify( + logbook._humanify( hass_, rows, entity_name_cache, event_cache, context_augmenter ), )