From 6b5735cd08529b6af1b532a4329749771e34b7c4 Mon Sep 17 00:00:00 2001 From: Aidan Timson Date: Mon, 26 Feb 2024 13:19:37 +0000 Subject: [PATCH 1/2] Add title to reauthenticate integration issue (#111275) * Add title to reauthenticate integration issue * Fix translation placeholder in test * Update translation placeholders in test_init.py * Update integration reauthentication message * Update string --- homeassistant/config_entries.py | 1 + homeassistant/strings.json | 2 +- tests/components/kitchen_sink/test_init.py | 4 ++-- tests/test_config_entries.py | 2 +- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/homeassistant/config_entries.py b/homeassistant/config_entries.py index d5259ef1fc5512..e11ad3e823ee6e 100644 --- a/homeassistant/config_entries.py +++ b/homeassistant/config_entries.py @@ -828,6 +828,7 @@ async def _async_init_reauth( issue_domain=self.domain, severity=ir.IssueSeverity.ERROR, translation_key="config_entry_reauth", + translation_placeholders={"name": self.title}, ) @callback diff --git a/homeassistant/strings.json b/homeassistant/strings.json index 6e6499e0d1939f..cfe1061bce6155 100644 --- a/homeassistant/strings.json +++ b/homeassistant/strings.json @@ -68,7 +68,7 @@ "config_flow": { "title": { "oauth2_pick_implementation": "Pick authentication method", - "reauth": "Reauthenticate integration", + "reauth": "Authentication expired for {name}", "via_hassio_addon": "{name} via Home Assistant add-on" }, "description": { diff --git a/tests/components/kitchen_sink/test_init.py b/tests/components/kitchen_sink/test_init.py index c65d53478d2083..b3f303fcfe1a1e 100644 --- a/tests/components/kitchen_sink/test_init.py +++ b/tests/components/kitchen_sink/test_init.py @@ -205,7 +205,7 @@ async def test_issues_created( "learn_more_url": None, "severity": "error", "translation_key": "config_entry_reauth", - "translation_placeholders": None, + "translation_placeholders": {"name": "Kitchen Sink"}, "ignored": False, }, ] @@ -322,7 +322,7 @@ async def test_issues_created( "learn_more_url": None, "severity": "error", "translation_key": "config_entry_reauth", - "translation_placeholders": None, + "translation_placeholders": {"name": "Kitchen Sink"}, "ignored": False, }, ] diff --git a/tests/test_config_entries.py b/tests/test_config_entries.py index 609f80e1a60de7..3941afbe1824ac 100644 --- a/tests/test_config_entries.py +++ b/tests/test_config_entries.py @@ -963,7 +963,7 @@ async def test_reauth_issue(hass: HomeAssistant) -> None: learn_more_url=None, severity=ir.IssueSeverity.ERROR, translation_key="config_entry_reauth", - translation_placeholders=None, + translation_placeholders={"name": "test_title"}, ) result = await hass.config_entries.flow.async_configure(issue.data["flow_id"], {}) From 8b8c607b01826a2b2767c344887b81cf83ef83bb Mon Sep 17 00:00:00 2001 From: Paulus Schoutsen Date: Tue, 27 Feb 2024 11:48:39 -0500 Subject: [PATCH 2/2] Bump version to 2024.2.5 --- homeassistant/const.py | 2 +- pyproject.toml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/homeassistant/const.py b/homeassistant/const.py index 4c1f1ab04487bc..7d0cee153e0f67 100644 --- a/homeassistant/const.py +++ b/homeassistant/const.py @@ -16,7 +16,7 @@ APPLICATION_NAME: Final = "HomeAssistant" MAJOR_VERSION: Final = 2024 MINOR_VERSION: Final = 2 -PATCH_VERSION: Final = "4" +PATCH_VERSION: Final = "5" __short_version__: Final = f"{MAJOR_VERSION}.{MINOR_VERSION}" __version__: Final = f"{__short_version__}.{PATCH_VERSION}" REQUIRED_PYTHON_VER: Final[tuple[int, int, int]] = (3, 11, 0) diff --git a/pyproject.toml b/pyproject.toml index 8f7c167edbf23e..c7ce83a783b9f8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta" [project] name = "homeassistant" -version = "2024.2.4" +version = "2024.2.5" license = {text = "Apache-2.0"} description = "Open-source home automation platform running on Python 3." readme = "README.rst"