From 7bbfb600390ff6206f08b3e779b6da8ac4fcf72b Mon Sep 17 00:00:00 2001 From: Stefan Agner Date: Thu, 24 Jun 2021 08:39:50 +0200 Subject: [PATCH] Allow upgrade when using {os_name} in URL (#2974) Once {os_name} is part of the update URL we also need to set the OS name explicitly for upgrades: A user might use a new Supervisor version on a OS release 5 device. The device will still use "hassos" as OS name. Before introducing {os_name}, the new OS name was part of the URL. Now when {os_name} is used, we need to adjust the name for upgrade as well. --- supervisor/hassos.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/supervisor/hassos.py b/supervisor/hassos.py index 41574aac2..b32223a1b 100644 --- a/supervisor/hassos.py +++ b/supervisor/hassos.py @@ -76,6 +76,8 @@ class HassOS(CoreSysAttributes): # The OS name used to be hassos before renaming to haos... if version < 6.0: update_os_name = "hassos" + else: + update_os_name = "haos" url = raw_url.format( version=str(version), board=update_board, os_name=update_os_name