From d99bc99d9beea3ede29789c064a48fb60959e6d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joakim=20S=C3=B8rensen?= Date: Fri, 8 Jan 2021 16:03:06 +0100 Subject: [PATCH] Prefix versions in system health (#44921) * Prefix versions in system health * Adjust test * Update homeassistant/components/hassio/strings.json --- homeassistant/components/hassio/system_health.py | 2 +- homeassistant/components/hassio/translations/en.json | 4 ++-- homeassistant/components/homeassistant/system_health.py | 2 +- tests/components/hassio/test_system_health.py | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/homeassistant/components/hassio/system_health.py b/homeassistant/components/hassio/system_health.py index 530703d3e25..47e9a3d2995 100644 --- a/homeassistant/components/hassio/system_health.py +++ b/homeassistant/components/hassio/system_health.py @@ -43,7 +43,7 @@ async def system_health_info(hass: HomeAssistant): information = { "host_os": host_info.get("operating_system"), "update_channel": info.get("channel"), - "supervisor_version": info.get("supervisor"), + "supervisor_version": f"supervisor-{info.get('supervisor')}", "docker_version": info.get("docker"), "disk_total": f"{host_info.get('disk_total')} GB", "disk_used": f"{host_info.get('disk_used')} GB", diff --git a/homeassistant/components/hassio/translations/en.json b/homeassistant/components/hassio/translations/en.json index 230e0c11fea..aadcdabfb94 100644 --- a/homeassistant/components/hassio/translations/en.json +++ b/homeassistant/components/hassio/translations/en.json @@ -9,11 +9,11 @@ "host_os": "Host Operating System", "installed_addons": "Installed Add-ons", "supervisor_api": "Supervisor API", - "supervisor_version": "Supervisor Version", + "supervisor_version": "Version", "supported": "Supported", "update_channel": "Update Channel", "version_api": "Version API" } }, - "title": "Hass.io" + "title": "Home Assistant Supervisor" } \ No newline at end of file diff --git a/homeassistant/components/homeassistant/system_health.py b/homeassistant/components/homeassistant/system_health.py index b0245d9beec..ff3562a24f9 100644 --- a/homeassistant/components/homeassistant/system_health.py +++ b/homeassistant/components/homeassistant/system_health.py @@ -17,7 +17,7 @@ async def system_health_info(hass): info = await system_info.async_get_system_info(hass) return { - "version": info.get("version"), + "version": f"core-{info.get('version')}", "installation_type": info.get("installation_type"), "dev": info.get("dev"), "hassio": info.get("hassio"), diff --git a/tests/components/hassio/test_system_health.py b/tests/components/hassio/test_system_health.py index 88eb7ea20f8..8fa610b5442 100644 --- a/tests/components/hassio/test_system_health.py +++ b/tests/components/hassio/test_system_health.py @@ -60,7 +60,7 @@ async def test_hassio_system_health(hass, aioclient_mock): "host_os": "Home Assistant OS 5.9", "installed_addons": "Awesome Addon (1.0.0)", "supervisor_api": "ok", - "supervisor_version": "2020.11.1", + "supervisor_version": "supervisor-2020.11.1", "supported": True, "update_channel": "stable", "version_api": "ok",