diff --git a/homeassistant/components/blinksticklight/__init__.py b/homeassistant/components/blinksticklight/__init__.py deleted file mode 100644 index 06375f0ab697..000000000000 --- a/homeassistant/components/blinksticklight/__init__.py +++ /dev/null @@ -1 +0,0 @@ -"""The BlinkStick integration.""" diff --git a/homeassistant/components/blinksticklight/light.py b/homeassistant/components/blinksticklight/light.py deleted file mode 100644 index e3af9cdaadc4..000000000000 --- a/homeassistant/components/blinksticklight/light.py +++ /dev/null @@ -1,87 +0,0 @@ -"""Support for BlinkStick lights.""" - -# mypy: ignore-errors -from typing import Any - -# from blinkstick import blinkstick -import voluptuous as vol - -from homeassistant.components.light import ( - ATTR_BRIGHTNESS, - ATTR_HS_COLOR, - PLATFORM_SCHEMA as LIGHT_PLATFORM_SCHEMA, - ColorMode, - LightEntity, -) -from homeassistant.const import CONF_NAME -from homeassistant.core import HomeAssistant -from homeassistant.helpers import config_validation as cv -from homeassistant.helpers.entity_platform import AddEntitiesCallback -from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType -from homeassistant.util import color as color_util - -CONF_SERIAL = "serial" - -DEFAULT_NAME = "Blinkstick" - -PLATFORM_SCHEMA = LIGHT_PLATFORM_SCHEMA.extend( - { - vol.Required(CONF_SERIAL): cv.string, - vol.Optional(CONF_NAME, default=DEFAULT_NAME): cv.string, - } -) - - -def setup_platform( - hass: HomeAssistant, - config: ConfigType, - add_entities: AddEntitiesCallback, - discovery_info: DiscoveryInfoType | None = None, -) -> None: - """Set up BlinkStick device specified by serial number.""" - - name = config[CONF_NAME] - serial = config[CONF_SERIAL] - - stick = blinkstick.find_by_serial(serial) - - add_entities([BlinkStickLight(stick, name)], True) - - -class BlinkStickLight(LightEntity): - """Representation of a BlinkStick light.""" - - _attr_color_mode = ColorMode.HS - _attr_supported_color_modes = {ColorMode.HS} - - def __init__(self, stick, name): - """Initialize the light.""" - self._stick = stick - self._attr_name = name - - def update(self) -> None: - """Read back the device state.""" - rgb_color = self._stick.get_color() - hsv = color_util.color_RGB_to_hsv(*rgb_color) - self._attr_hs_color = hsv[:2] - self._attr_brightness = int(hsv[2]) - self._attr_is_on = self.brightness is not None and self.brightness > 0 - - def turn_on(self, **kwargs: Any) -> None: - """Turn the device on.""" - if ATTR_HS_COLOR in kwargs: - self._attr_hs_color = kwargs[ATTR_HS_COLOR] - - brightness: int = kwargs.get(ATTR_BRIGHTNESS, 255) - self._attr_brightness = brightness - self._attr_is_on = bool(brightness) - - assert self.hs_color - rgb_color = color_util.color_hsv_to_RGB( - self.hs_color[0], self.hs_color[1], brightness / 255 * 100 - ) - self._stick.set_color(red=rgb_color[0], green=rgb_color[1], blue=rgb_color[2]) - - def turn_off(self, **kwargs: Any) -> None: - """Turn the device off.""" - self._stick.turn_off() diff --git a/homeassistant/components/blinksticklight/manifest.json b/homeassistant/components/blinksticklight/manifest.json deleted file mode 100644 index d3592b6af6e2..000000000000 --- a/homeassistant/components/blinksticklight/manifest.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "domain": "blinksticklight", - "name": "BlinkStick", - "codeowners": [], - "disabled": "This integration is disabled because it uses non-open source code to operate.", - "documentation": "https://www.home-assistant.io/integrations/blinksticklight", - "iot_class": "local_polling", - "loggers": ["blinkstick"], - "quality_scale": "legacy", - "requirements": ["BlinkStick==1.2.0"] -} diff --git a/homeassistant/components/blinksticklight/ruff.toml b/homeassistant/components/blinksticklight/ruff.toml deleted file mode 100644 index 1b02a0b8eafe..000000000000 --- a/homeassistant/components/blinksticklight/ruff.toml +++ /dev/null @@ -1,5 +0,0 @@ -extend = "../../../pyproject.toml" - -lint.extend-ignore = [ - "F821" -] \ No newline at end of file diff --git a/homeassistant/generated/integrations.json b/homeassistant/generated/integrations.json index c1f0ae909868..5e22346b3e51 100644 --- a/homeassistant/generated/integrations.json +++ b/homeassistant/generated/integrations.json @@ -764,12 +764,6 @@ "config_flow": true, "iot_class": "cloud_polling" }, - "blinksticklight": { - "name": "BlinkStick", - "integration_type": "hub", - "config_flow": false, - "iot_class": "local_polling" - }, "bliss_automation": { "name": "Bliss Automation", "integration_type": "virtual", diff --git a/script/hassfest/quality_scale.py b/script/hassfest/quality_scale.py index b2dc81b704c9..46cedcf527eb 100644 --- a/script/hassfest/quality_scale.py +++ b/script/hassfest/quality_scale.py @@ -189,7 +189,6 @@ INTEGRATIONS_WITHOUT_QUALITY_SCALE_FILE = [ "blackbird", "blebox", "blink", - "blinksticklight", "blockchain", "blue_current", "bluemaestro", @@ -1133,7 +1132,6 @@ INTEGRATIONS_WITHOUT_SCALE = [ "blackbird", "blebox", "blink", - "blinksticklight", "blockchain", "blue_current", "bluemaestro",