1
0
mirror of https://github.com/esphome/esphome.git synced 2025-10-13 15:23:49 +01:00
This commit is contained in:
J. Nick Koston
2025-10-09 06:17:12 -10:00
parent 3d58ec769c
commit c162970ec5

View File

@@ -217,9 +217,11 @@ def analyze_component(component_dir: Path) -> tuple[dict[str, list[str]], bool]:
if yaml_file.name.startswith("test.") and yaml_file.suffix == ".yaml": if yaml_file.name.startswith("test.") and yaml_file.suffix == ".yaml":
# Extract platform name (e.g., test.esp32-ard.yaml -> esp32-ard) # Extract platform name (e.g., test.esp32-ard.yaml -> esp32-ard)
platform = yaml_file.stem.replace("test.", "") platform = yaml_file.stem.replace("test.", "")
if analysis["buses"]: # Always add platform, even if it has no buses (empty list)
# Sort for consistent comparison # This allows grouping components that don't use any shared buses
platform_buses[platform] = sorted(analysis["buses"]) platform_buses[platform] = (
sorted(analysis["buses"]) if analysis["buses"] else []
)
return platform_buses, has_extend_remove return platform_buses, has_extend_remove