diff --git a/zha/application/__init__.py b/zha/application/__init__.py index bf2d34d8..385cc969 100644 --- a/zha/application/__init__.py +++ b/zha/application/__init__.py @@ -6,45 +6,21 @@ class Platform(StrEnum): """Available entity platforms.""" - AIR_QUALITY = "air_quality" ALARM_CONTROL_PANEL = "alarm_control_panel" BINARY_SENSOR = "binary_sensor" BUTTON = "button" - CALENDAR = "calendar" - CAMERA = "camera" CLIMATE = "climate" COVER = "cover" - DATE = "date" - DATETIME = "datetime" DEVICE_TRACKER = "device_tracker" EVENT = "event" FAN = "fan" - GEO_LOCATION = "geo_location" - HUMIDIFIER = "humidifier" - IMAGE = "image" - IMAGE_PROCESSING = "image_processing" - LAWN_MOWER = "lawn_mower" LIGHT = "light" LOCK = "lock" - MAILBOX = "mailbox" - MEDIA_PLAYER = "media_player" - NOTIFY = "notify" NUMBER = "number" - REMOTE = "remote" - SCENE = "scene" SELECT = "select" SENSOR = "sensor" SIREN = "siren" - STT = "stt" SWITCH = "switch" - TEXT = "text" - TIME = "time" - TODO = "todo" - TTS = "tts" - VACUUM = "vacuum" VALVE = "valve" UNKNOWN = "unknown" UPDATE = "update" - WAKE_WORD = "wake_word" - WATER_HEATER = "water_heater" - WEATHER = "weather" diff --git a/zha/application/const.py b/zha/application/const.py index 6d39c0c8..1b79f151 100644 --- a/zha/application/const.py +++ b/zha/application/const.py @@ -1,9 +1,8 @@ -"""All constants related to the ZHA component.""" +"""Constants for ZHA.""" from __future__ import annotations import enum -import logging from numbers import Number from typing import Any, Final @@ -188,26 +187,6 @@ def __voluptuous_compile__(self, schema: vol.Schema) -> Any: # pylint: disable= DATA_ZHA_DEVICE_TRIGGER_CACHE = "zha_device_trigger_cache" DATA_ZHA_GATEWAY = "zha_gateway" -DEBUG_COMP_BELLOWS = "bellows" -DEBUG_COMP_ZHA = "homeassistant.components.zha" -DEBUG_COMP_ZIGPY = "zigpy" -DEBUG_COMP_ZIGPY_ZNP = "zigpy_znp" -DEBUG_COMP_ZIGPY_DECONZ = "zigpy_deconz" -DEBUG_COMP_ZIGPY_XBEE = "zigpy_xbee" -DEBUG_COMP_ZIGPY_ZIGATE = "zigpy_zigate" -DEBUG_LEVEL_CURRENT = "current" -DEBUG_LEVEL_ORIGINAL = "original" -DEBUG_LEVELS = { - DEBUG_COMP_BELLOWS: logging.DEBUG, - DEBUG_COMP_ZHA: logging.DEBUG, - DEBUG_COMP_ZIGPY: logging.DEBUG, - DEBUG_COMP_ZIGPY_ZNP: logging.DEBUG, - DEBUG_COMP_ZIGPY_DECONZ: logging.DEBUG, - DEBUG_COMP_ZIGPY_XBEE: logging.DEBUG, - DEBUG_COMP_ZIGPY_ZIGATE: logging.DEBUG, -} -DEBUG_RELAY_LOGGERS = [DEBUG_COMP_ZHA, DEBUG_COMP_ZIGPY] - DEFAULT_RADIO_TYPE = "ezsp" DEFAULT_BAUDRATE = 57600 DEFAULT_DATABASE_NAME = "zigbee.db" diff --git a/zha/application/discovery.py b/zha/application/discovery.py index 290d20b1..3ecf2b76 100644 --- a/zha/application/discovery.py +++ b/zha/application/discovery.py @@ -427,7 +427,7 @@ def probe_single_cluster( cluster_handler: ClusterHandler, endpoint: Endpoint, ) -> None: - """Probe specified cluster for specific component.""" + """Probe specified cluster for specific platform.""" if platform is None or platform not in PLATFORMS: return cluster_handler_list = [cluster_handler] @@ -544,7 +544,7 @@ def initialize(self, gateway: Gateway) -> None: class GroupProbe: - """Determine the appropriate component for a group.""" + """Determine the appropriate platform for a group.""" def __init__(self) -> None: """Initialize instance.""" diff --git a/zha/application/helpers.py b/zha/application/helpers.py index 34366711..bb6a5e38 100644 --- a/zha/application/helpers.py +++ b/zha/application/helpers.py @@ -1,8 +1,4 @@ -"""Helpers for Zigbee Home Automation. - -For more details about this component, please refer to the documentation at -https://home-assistant.io/integrations/zha/ -""" +"""Helpers for Zigbee Home Automation.""" from __future__ import annotations diff --git a/zha/application/platforms/__init__.py b/zha/application/platforms/__init__.py index 3fa1e3d1..cd0fd55c 100644 --- a/zha/application/platforms/__init__.py +++ b/zha/application/platforms/__init__.py @@ -29,12 +29,7 @@ class EntityCategory(StrEnum): - """Category of an entity. - - An entity with a category will: - - Not be exposed to cloud, Alexa, or Google Assistant components - - Not be included in indirect service calls to devices or areas - """ + """Category of an entity.""" # Config: An entity which allows changing the configuration of a device. CONFIG = "config" diff --git a/zha/application/platforms/binary_sensor/__init__.py b/zha/application/platforms/binary_sensor/__init__.py index 866c8813..f55a12e0 100644 --- a/zha/application/platforms/binary_sensor/__init__.py +++ b/zha/application/platforms/binary_sensor/__init__.py @@ -233,7 +233,7 @@ def translation_key(self) -> str | None: @property def device_class(self) -> BinarySensorDeviceClass | None: - """Return device class from component DEVICE_CLASSES.""" + """Return device class from platform DEVICE_CLASSES.""" zone_type = self._cluster_handler.cluster.get("zone_type") return IAS_ZONE_CLASS_MAPPING.get(zone_type) diff --git a/zha/zigbee/cluster_handlers/hvac.py b/zha/zigbee/cluster_handlers/hvac.py index 450d1461..a91cf810 100644 --- a/zha/zigbee/cluster_handlers/hvac.py +++ b/zha/zigbee/cluster_handlers/hvac.py @@ -1,8 +1,4 @@ -"""HVAC cluster handlers module for Zigbee Home Automation. - -For more details about this component, please refer to the documentation at -https://home-assistant.io/integrations/zha/ -""" +"""HVAC cluster handlers module for Zigbee Home Automation.""" from __future__ import annotations diff --git a/zha/zigbee/cluster_handlers/security.py b/zha/zigbee/cluster_handlers/security.py index 47e29177..db0864e4 100644 --- a/zha/zigbee/cluster_handlers/security.py +++ b/zha/zigbee/cluster_handlers/security.py @@ -1,8 +1,4 @@ -"""Security cluster handlers module for Zigbee Home Automation. - -For more details about this component, please refer to the documentation at -https://home-assistant.io/integrations/zha/ -""" +"""Security cluster handlers module for Zigbee Home Automation.""" from __future__ import annotations