From df999723f86b42697b8018fa860289134f048afd Mon Sep 17 00:00:00 2001 From: Jesse Hills <3060199+jesserockz@users.noreply.github.com> Date: Mon, 9 May 2022 19:43:09 +1200 Subject: [PATCH] Force using name substitution when adopting a device (#3451) --- esphome/components/dashboard_import/__init__.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/esphome/components/dashboard_import/__init__.py b/esphome/components/dashboard_import/__init__.py index 6194a55205..41b4a8bed1 100644 --- a/esphome/components/dashboard_import/__init__.py +++ b/esphome/components/dashboard_import/__init__.py @@ -64,7 +64,10 @@ def import_config(path: str, name: str, project_name: str, import_url: str) -> N config = { "substitutions": {"name": name}, "packages": {project_name: import_url}, - "esphome": {"name_add_mac_suffix": False}, + "esphome": { + "name": "${name}", + "name_add_mac_suffix": False, + }, } p.write_text( dump(config) + WIFI_CONFIG,