From 9667e14f5b2cc58746c2ff3082810322d85f1171 Mon Sep 17 00:00:00 2001 From: f1devbin <280303226+f1devbin@users.noreply.github.com> Date: Sat, 14 Nov 2026 00:44:40 +0300 Subject: [PATCH] Pass hassfest: manifest categories and connectivity, no URL in translations Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01MkKGsvEe19sQiDs5dtMkjo --- custom_components/c6_zigbee_stick/config_flow.py | 16 +++++++++++++--- custom_components/c6_zigbee_stick/const.py | 1 + custom_components/c6_zigbee_stick/manifest.json | 2 ++ custom_components/c6_zigbee_stick/strings.json | 2 +- .../c6_zigbee_stick/translations/en.json | 2 +- .../c6_zigbee_stick/translations/ru.json | 2 +- 6 files changed, 19 insertions(+), 6 deletions(-) diff --git a/custom_components/c6_zigbee_stick/config_flow.py b/custom_components/c6_zigbee_stick/config_flow.py index 2f5773c..9591d8e 100644 --- a/custom_components/c6_zigbee_stick/config_flow.py +++ b/custom_components/c6_zigbee_stick/config_flow.py @@ -15,7 +15,17 @@ from homeassistant.helpers.service_info.usb import UsbServiceInfo from . import zboss -from .const import ADAPTER, CONF_DEVICE, CONF_FIRMWARE, CONF_SERIAL, DOMAIN, LOGGER, USB_PID, USB_VID +from .const import ( + ADAPTER, + CONF_DEVICE, + CONF_FIRMWARE, + CONF_SERIAL, + DOMAIN, + FLASHER_URL, + LOGGER, + USB_PID, + USB_VID, +) from .z2m import async_current_serial, async_setup_z2m TITLE = "C6 Zigbee Stick" @@ -77,7 +87,7 @@ async def async_step_usb(self, discovery_info: UsbServiceInfo) -> ConfigFlowResu if reason := await self._async_check(device, discovery_info.serial_number): # Silent for USB discovery: other ESP32 boards share this USB id. - return self.async_abort(reason=reason) + return self.async_abort(reason=reason, description_placeholders={"url": FLASHER_URL}) self.context["title_placeholders"] = {"name": TITLE} return await self.async_step_confirm() @@ -104,7 +114,7 @@ async def async_step_user(self, user_input: dict[str, Any] | None = None) -> Con continue await self.async_set_unique_id(serial) return await self.async_step_confirm() - return self.async_abort(reason=last_reason) + return self.async_abort(reason=last_reason, description_placeholders={"url": FLASHER_URL}) async def async_step_confirm(self, user_input: dict[str, Any] | None = None) -> ConfigFlowResult: """Show what was found and what will be done.""" diff --git a/custom_components/c6_zigbee_stick/const.py b/custom_components/c6_zigbee_stick/const.py index 89e472a..8f55aae 100644 --- a/custom_components/c6_zigbee_stick/const.py +++ b/custom_components/c6_zigbee_stick/const.py @@ -7,6 +7,7 @@ # ESP32-C6 built-in USB-Serial/JTAG. Fixed in silicon, so every C6 board looks like this; # the ZBOSS probe tells our coordinator apart from other ESP32 firmware. +FLASHER_URL = "https://f1devbin.github.io/c6-zigbee-stick/" USB_VID = "303A" USB_PID = "1001" diff --git a/custom_components/c6_zigbee_stick/manifest.json b/custom_components/c6_zigbee_stick/manifest.json index 9c62d7c..4dcfd80 100644 --- a/custom_components/c6_zigbee_stick/manifest.json +++ b/custom_components/c6_zigbee_stick/manifest.json @@ -2,8 +2,10 @@ "domain": "c6_zigbee_stick", "name": "C6 Zigbee Stick", "after_dependencies": ["hassio", "mqtt"], + "categories": ["hubs_protocols.wireless_protocols", "diy_makers.boards_hardware"], "codeowners": ["@f1devbin"], "config_flow": true, + "connectivity": ["zigbee"], "dependencies": ["usb"], "documentation": "https://github.com/f1devbin/c6-zigbee-stick", "integration_type": "device", diff --git a/custom_components/c6_zigbee_stick/strings.json b/custom_components/c6_zigbee_stick/strings.json index a8996e5..9e88c99 100644 --- a/custom_components/c6_zigbee_stick/strings.json +++ b/custom_components/c6_zigbee_stick/strings.json @@ -13,7 +13,7 @@ "abort": { "already_configured": "This stick is already set up.", "no_devices_found": "No ESP32-C6 is connected over USB.", - "not_zboss": "The ESP32-C6 does not answer as a Zigbee coordinator. Flash the coordinator firmware first: https://f1devbin.github.io/c6-zigbee-stick/", + "not_zboss": "The ESP32-C6 does not answer as a Zigbee coordinator. Flash the coordinator firmware first: {url}", "port_busy": "The port is in use by another program.", "z2m_other_adapter": "Zigbee2MQTT already works with another adapter, so it was left as it is.", "z2m_setup_failed": "Zigbee2MQTT could not be set up: {error}" diff --git a/custom_components/c6_zigbee_stick/translations/en.json b/custom_components/c6_zigbee_stick/translations/en.json index a8996e5..9e88c99 100644 --- a/custom_components/c6_zigbee_stick/translations/en.json +++ b/custom_components/c6_zigbee_stick/translations/en.json @@ -13,7 +13,7 @@ "abort": { "already_configured": "This stick is already set up.", "no_devices_found": "No ESP32-C6 is connected over USB.", - "not_zboss": "The ESP32-C6 does not answer as a Zigbee coordinator. Flash the coordinator firmware first: https://f1devbin.github.io/c6-zigbee-stick/", + "not_zboss": "The ESP32-C6 does not answer as a Zigbee coordinator. Flash the coordinator firmware first: {url}", "port_busy": "The port is in use by another program.", "z2m_other_adapter": "Zigbee2MQTT already works with another adapter, so it was left as it is.", "z2m_setup_failed": "Zigbee2MQTT could not be set up: {error}" diff --git a/custom_components/c6_zigbee_stick/translations/ru.json b/custom_components/c6_zigbee_stick/translations/ru.json index 302ac5e..f438611 100644 --- a/custom_components/c6_zigbee_stick/translations/ru.json +++ b/custom_components/c6_zigbee_stick/translations/ru.json @@ -13,7 +13,7 @@ "abort": { "already_configured": "Этот стик уже настроен.", "no_devices_found": "ESP32-C6 по USB не подключена.", - "not_zboss": "ESP32-C6 не отвечает как Zigbee-координатор. Сначала прошейте её: https://f1devbin.github.io/c6-zigbee-stick/", + "not_zboss": "ESP32-C6 не отвечает как Zigbee-координатор. Сначала прошейте её: {url}", "port_busy": "Порт занят другой программой.", "z2m_other_adapter": "Zigbee2MQTT уже работает с другим адаптером, поэтому его не трогали.", "z2m_setup_failed": "Не удалось настроить Zigbee2MQTT: {error}"