Compare commits

..

96 Commits

Author SHA1 Message Date
Franck Nijhof ef6fed5067 Bump version to 2024.2.0b4 2024-02-03 14:42:00 +01:00
Jan-Philipp Benecke 0a627aed6d Fix Tankerkoenig diagnostics file to use right format (#109494)
Fix tankerkoenig diagnostics file
2024-02-03 14:40:26 +01:00
Joakim Sørensen cb03a6e29b Change IoT class for Traccar Client (#109493) 2024-02-03 14:40:23 +01:00
Joakim Sørensen e630027455 Extend the history of Elvia history to 3 years (#109490)
Extend the history of Elvia data to 3 years
2024-02-03 14:40:21 +01:00
G Johansson 280d7ef4ec Add new climate feature flags to deconz (#109482) 2024-02-03 14:40:18 +01:00
G Johansson 93b7ffa807 Add new climate feature flags to demo (#109481) 2024-02-03 14:40:15 +01:00
G Johansson cc8e9ac141 Adds new climate feature flags to bsblan (#109480) 2024-02-03 14:40:12 +01:00
G Johansson 2724b115da Adds new climate feature flags to broadlink (#109479) 2024-02-03 14:40:09 +01:00
G Johansson 150fb151fa Add new climate feature flags to blebox (#109478) 2024-02-03 14:40:06 +01:00
G Johansson 4b8cb35ba0 Adds migrated climate feature flags in balboa (#109477) 2024-02-03 14:40:03 +01:00
G Johansson 5cce878b85 Adds new climate feature flags in baf (#109476) 2024-02-03 14:40:00 +01:00
G Johansson 92ebc5b436 Adds new climate feature flags to ambiclimate (#109475) 2024-02-03 14:39:57 +01:00
G Johansson 463320c8ee Adds migrated climate feature flags in nuheat (#109474) 2024-02-03 14:39:54 +01:00
G Johansson 3bf5fa9302 Adds migrated climate feature flags to nobo_hub (#109473) 2024-02-03 14:39:51 +01:00
G Johansson 650ab70444 Add migrated climate feature flags to nexia (#109472) 2024-02-03 14:39:48 +01:00
G Johansson bb8a74a3f4 Add new climate feature flags to mysensors (#109471)
Adds new climate feature flags to mysensors
2024-02-03 14:39:45 +01:00
G Johansson 49445c46a0 Add migrated climate feature flags to moehlenhoff (#109470) 2024-02-03 14:39:42 +01:00
G Johansson 490101fa92 Adds new climate feature flags to melissa (#109469) 2024-02-03 14:39:39 +01:00
G Johansson 2ac4bb8e9f Add new feature flags to melcloud (#109468) 2024-02-03 14:39:36 +01:00
G Johansson 1c0a6970e2 Adds new climate feature flags to maxcube (#109467) 2024-02-03 14:39:33 +01:00
G Johansson f3f69a8107 Add new climate feature flags to radiotherm (#109466) 2024-02-03 14:39:30 +01:00
G Johansson a77bcccbbb Adds migrated climate feature flags for proliphix (#109465) 2024-02-03 14:39:28 +01:00
G Johansson e98da8596a Add migrated climate feature flags to overkiz (#109463) 2024-02-03 14:39:25 +01:00
G Johansson 5843c93371 Add migrated climate feature flags to opentherm_gw (#109462) 2024-02-03 14:39:22 +01:00
G Johansson 5991b06574 Add new climate feature flags to oem (#109461) 2024-02-03 14:39:19 +01:00
G Johansson fecdfbfb9f Add new climate feature flags to stiebel_eltron (#109457) 2024-02-03 14:39:16 +01:00
G Johansson 8cfe3821da Add migrated climate feature flags to senz (#109455) 2024-02-03 14:39:13 +01:00
G Johansson cba67d1525 Add new climate feature flags to screenlogic (#109454) 2024-02-03 14:39:10 +01:00
G Johansson 39df394414 Add migrated climate feature flags to schluter (#109452) 2024-02-03 14:39:07 +01:00
G Johansson db91a40b55 Add migrated climate feature flags to touchline (#109451) 2024-02-03 14:39:04 +01:00
G Johansson 3181358484 Add migrated climate feature flags to toon (#109450) 2024-02-03 14:39:01 +01:00
G Johansson 776e2da4e6 Add migrated climate feature flags to tolo (#109449) 2024-02-03 14:38:58 +01:00
G Johansson 72ffdf4f4b Add new climate feature flags to tfiac (#109448) 2024-02-03 14:38:55 +01:00
G Johansson 36bba95fd0 Add migrated climate feature flags for tessie (#109447) 2024-02-03 14:38:52 +01:00
G Johansson 13fc69d8a8 Add migrated climate feature flags to teslemetry (#109446) 2024-02-03 14:38:49 +01:00
G Johansson 94464f220c Add migrated climate feature flags to zwave_me (#109445) 2024-02-03 14:38:46 +01:00
G Johansson 13decb9b10 Add new climate feature flags to zhong_hong (#109444) 2024-02-03 14:38:44 +01:00
G Johansson b6226acd2b Add migrated climate feature flags to zha (#109443) 2024-02-03 14:38:41 +01:00
G Johansson d04282a41c Add new climate feature flags to yolink (#109442) 2024-02-03 14:38:38 +01:00
G Johansson a671d0bc6c Add migrated climate feature flags to xs1 (#109441) 2024-02-03 14:38:35 +01:00
G Johansson 6c84e8dff0 Add new climate feature flags to whirlpool (#109440) 2024-02-03 14:38:32 +01:00
G Johansson 57279b1c7b Add migrated climate feature flags to vicare (#109439) 2024-02-03 14:38:29 +01:00
G Johansson a5646e0df2 Add migrated feature flags to vera (#109438) 2024-02-03 14:38:26 +01:00
Teemu R 63ad3ebdf4 Add new OUIs for tplink (#109437) 2024-02-03 14:38:23 +01:00
G Johansson f2a9ef6591 Add new climate feature flags to venstar (#109436) 2024-02-03 14:38:21 +01:00
G Johansson 2a5bb66c06 Adds migrated climate entity feature for velbus (#109435) 2024-02-03 14:38:18 +01:00
G Johansson 0c0be6d6a1 Add migrated climate feature flags to homekit_controller (#109433) 2024-02-03 14:38:15 +01:00
G Johansson e99a58ad53 Add new climate feature flags to flexit_bacnet (#109431) 2024-02-03 14:38:12 +01:00
G Johansson 6c4b773bc1 Add migrated climate entity features to flexit (#109430) 2024-02-03 14:38:09 +01:00
G Johansson c571f36c6c Add new climate feature flags to evohome (#109429) 2024-02-03 14:38:06 +01:00
G Johansson f1b041afbe Add migrated climate feature flags to smarttub (#109427) 2024-02-03 14:38:03 +01:00
G Johansson 183af92658 Add migrated climate feature flags to smartthings (#109426) 2024-02-03 14:38:00 +01:00
G Johansson d71dd12263 Add migrated climate feature flags to shelly (#109425) 2024-02-03 14:37:57 +01:00
G Johansson 18a7aa20b4 Adds new climate feature flags for airzone_cloud (#109424) 2024-02-03 14:37:54 +01:00
G Johansson f8fde71ef3 Add new climate feature flags to airzone (#109423) 2024-02-03 14:37:51 +01:00
G Johansson 966798b588 Add migrated ClimateEntityFeatures to advantage_air (#109420)
* Add migrated ClimateEntityFeatures to advantage_air

* AdvantageAirZone
2024-02-03 14:37:48 +01:00
G Johansson 66b6f81996 Add migrated ClimateEntityFeature to MQTT (#109419) 2024-02-03 14:37:45 +01:00
G Johansson 4a1a5b9e87 Adds migrated ClimateEntityFeature to Netatmo (#109418) 2024-02-03 14:37:42 +01:00
G Johansson f01f033b3f Add ClimateEntityFeatures to Nest (#109417) 2024-02-03 14:37:39 +01:00
G Johansson cd884de79e Add new ClimateEntityFeature for Tado (#109416) 2024-02-03 14:37:36 +01:00
G Johansson 14be7e4a72 Add Mill migrated ClimateEntityFeatures (#109415) 2024-02-03 14:37:32 +01:00
Jc2k 2be71d53c5 Bump aiohomekit to 3.1.4 (#109414) 2024-02-03 14:37:25 +01:00
Michael Hansen 1c960d300d Bump intents to 2024.2.2 (#109412)
Bump intents to 2024.2.2
2024-02-03 14:35:31 +01:00
Michael Hansen 87a1482e4d Pass slots to error messages instead of IDs [rework] (#109410)
Co-authored-by: tetele <tm.sandu@gmail.com>
2024-02-03 14:33:14 +01:00
Jan-Philipp Benecke 24b8e60978 Bump aiotankerkoenig to 0.3.0 (#109404) 2024-02-03 14:23:42 +01:00
Jurriaan Pruis 404e30911b Bump matrix-nio to 0.24.0 (#109403)
Update matrix-nio to 0.24.0
2024-02-03 14:23:38 +01:00
wilburCforce 9c599f7513 Fix device type in Lutron (#109401)
remove testing code
2024-02-03 14:23:35 +01:00
Jan-Philipp Benecke f3e8360949 Bump aioelectricitymaps to 0.3.0 (#109399)
* Bump aioelectricitymaps to 0.3.0

* Fix tests
2024-02-03 14:23:32 +01:00
Teemu R 43f8731f8a Bump python-kasa to 0.6.2.1 (#109397) 2024-02-03 14:23:29 +01:00
Michael Hansen 4a60d36216 More thorough checks in ESPHome voice assistant UDP server (#109394)
* More thorough checks in UDP server

* Simplify and change to stop_requested

* Check transport
2024-02-03 14:23:26 +01:00
Michael 07a1ee0baa Add diagnostics to proximity (#109393) 2024-02-03 14:23:23 +01:00
Franck Nijhof a57c30be88 Update elgato to 5.1.2 (#109391) 2024-02-03 14:23:20 +01:00
jjlawren b1bf69689e Do not suggest area for portable Sonos speakers (#109350)
* Do not suggest area for portable speakers

* Update tests

* Improve readability, update tests
2024-02-03 14:23:17 +01:00
Christopher Fenner 4735aadaa8 Ignore gateway devices in ViCare integration (#106477)
* filter unsupported devices

* Update __init__.py

* use debug

* remove dead code
2024-02-03 14:23:13 +01:00
Franck Nijhof f18f161efa Bump version to 2024.2.0b3 2024-02-02 17:36:51 +01:00
Bram Kragten 3c90e3d83f Update frontend to 20240202.0 (#109388) 2024-02-02 17:36:43 +01:00
Robert Resch 57a43ef151 Improve Ecovacs naming (#109372) 2024-02-02 17:36:40 +01:00
Franck Nijhof 6afc6ca126 Remove suggested area from Verisure (#109364) 2024-02-02 17:36:37 +01:00
Joakim Sørensen 92a3edc536 Specify end_time when importing Elvia data to deal with drift (#109361) 2024-02-02 17:36:34 +01:00
Robert Resch e91e67b400 Bump deebot_client to 5.1.0 (#109360) 2024-02-02 17:36:31 +01:00
Franck Nijhof 7a7bcf1a92 Update cryptography to 42.0.2 (#109359) 2024-02-02 17:36:28 +01:00
karwosts 1383a0c13a Missing template helper translation keys (#109347) 2024-02-02 17:36:24 +01:00
J. Nick Koston 12e3077895 Ensure the purge entities service cleans up the states_meta table (#109344) 2024-02-02 17:36:21 +01:00
G Johansson 05c0973937 Add Adax migrated ClimateEntityFeatures (#109341) 2024-02-02 17:36:18 +01:00
G Johansson 7467d588c8 Add sensibo migrated ClimateEntityFeatures (#109340)
Adds sensibo migrated ClimateEntityFeatures
2024-02-02 17:36:15 +01:00
jan iversen 0c82e0a618 Correct modbus commit validation, too strict on integers (#109338) 2024-02-02 17:36:12 +01:00
J. Nick Koston 5a4f88349a Fix stale camera error message in img_util (#109325) 2024-02-02 17:36:09 +01:00
G Johansson e720e82fd6 Add migrated ClimateEntityFeature for Nibe Heat Pump (#109140) 2024-02-02 17:36:05 +01:00
G Johansson 8ed0af2fb7 Add TURN_ON/OFF ClimateEntityFeature for KNX (#109138) 2024-02-02 17:36:02 +01:00
G Johansson 550c0bf3c3 Add migrated ClimateEntityFeature for SwitchBot Cloud (#109136) 2024-02-02 17:35:59 +01:00
G Johansson 8bb98b4146 Add TURN_ON/OFF ClimateEntityFeature for Modbus (#109133) 2024-02-02 17:35:56 +01:00
G Johansson bd5bc6b83d Add TURN_ON/OFF ClimateEntityFeature for Matter (#108974)
* Add TURN_ON/OFF ClimateEntityFeature for Matter

* Adjust matter
2024-02-02 17:35:53 +01:00
G Johansson a2b6b0a0bc Add TURN_ON/OFF ClimateEntityFeature for Fibaro (#108963) 2024-02-02 17:35:50 +01:00
G Johansson 41ad3d8987 Add migrated ClimateEntityFeature for Atag (#108961) 2024-02-02 17:35:45 +01:00
mkmer 3e7dc3588d Add independent session in honeywell (#108435) 2024-02-02 17:35:42 +01:00
Cyrill Raccaud 66d802b5e5 Follow up swiss_public_transport migration fix of unique ids (#107873)
improve migration fix of unique ids
- follow up to #107087
2024-02-02 17:35:38 +01:00
146 changed files with 1217 additions and 494 deletions
+1
View File
@@ -74,6 +74,7 @@ class AdaxDevice(ClimateEntity):
)
_attr_target_temperature_step = PRECISION_WHOLE
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, heater_data: dict[str, Any], adax_data_handler: Adax) -> None:
"""Initialize the heater."""
@@ -83,6 +83,7 @@ class AdvantageAirAC(AdvantageAirAcEntity, ClimateEntity):
_attr_max_temp = 32
_attr_min_temp = 16
_attr_name = None
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, instance: AdvantageAirData, ac_key: str) -> None:
"""Initialize an AdvantageAir AC unit."""
@@ -202,11 +203,16 @@ class AdvantageAirZone(AdvantageAirZoneEntity, ClimateEntity):
"""AdvantageAir MyTemp Zone control."""
_attr_hvac_modes = [HVACMode.OFF, HVACMode.HEAT_COOL]
_attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_target_temperature_step = PRECISION_WHOLE
_attr_max_temp = 32
_attr_min_temp = 16
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, instance: AdvantageAirData, ac_key: str, zone_key: str) -> None:
"""Initialize an AdvantageAir Zone control."""
+6 -1
View File
@@ -117,6 +117,7 @@ class AirzoneClimate(AirzoneZoneEntity, ClimateEntity):
_attr_name = None
_speeds: dict[int, str] = {}
_speeds_reverse: dict[str, int] = {}
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self,
@@ -129,7 +130,11 @@ class AirzoneClimate(AirzoneZoneEntity, ClimateEntity):
super().__init__(coordinator, entry, system_zone_id, zone_data)
self._attr_unique_id = f"{self._attr_unique_id}_{system_zone_id}"
self._attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
self._attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
self._attr_target_temperature_step = API_TEMPERATURE_STEP
self._attr_temperature_unit = TEMP_UNIT_LIB_TO_HASS[
self.get_airzone_value(AZD_TEMP_UNIT)
@@ -144,8 +144,13 @@ class AirzoneClimate(AirzoneEntity, ClimateEntity):
"""Define an Airzone Cloud climate."""
_attr_name = None
_attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
@callback
def _handle_coordinator_update(self) -> None:
@@ -153,10 +153,15 @@ class AmbiclimateEntity(ClimateEntity):
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_target_temperature_step = 1
_attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_attr_hvac_modes = [HVACMode.HEAT, HVACMode.OFF]
_attr_has_entity_name = True
_attr_name = None
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, heater: AmbiclimateDevice, store: Store[dict[str, Any]]) -> None:
"""Initialize the thermostat."""
+1
View File
@@ -46,6 +46,7 @@ class AtagThermostat(AtagEntity, ClimateEntity):
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE | ClimateEntityFeature.PRESET_MODE
)
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, coordinator, atag_id):
"""Initialize an Atag climate device."""
+6 -1
View File
@@ -33,10 +33,15 @@ async def async_setup_entry(
class BAFAutoComfort(BAFEntity, ClimateEntity):
"""BAF climate auto comfort."""
_attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_hvac_modes = [HVACMode.OFF, HVACMode.FAN_ONLY]
_attr_translation_key = "auto_comfort"
_enable_turn_on_off_backwards_compatibility = False
@callback
def _async_update_attrs(self) -> None:
@@ -63,6 +63,7 @@ class BalboaClimateEntity(BalboaEntity, ClimateEntity):
)
_attr_translation_key = DOMAIN
_attr_name = None
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, client: SpaClient) -> None:
"""Initialize the climate entity."""
+6 -1
View File
@@ -53,8 +53,13 @@ async def async_setup_entry(
class BleBoxClimateEntity(BleBoxEntity[blebox_uniapi.climate.Climate], ClimateEntity):
"""Representation of a BleBox climate feature (saunaBox)."""
_attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
@property
def hvac_modes(self):
@@ -35,9 +35,14 @@ class BroadlinkThermostat(ClimateEntity, BroadlinkEntity):
_attr_has_entity_name = True
_attr_hvac_modes = [HVACMode.HEAT, HVACMode.OFF, HVACMode.AUTO]
_attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_attr_target_temperature_step = PRECISION_HALVES
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, device: BroadlinkDevice) -> None:
"""Initialize the climate entity."""
+5 -1
View File
@@ -73,12 +73,16 @@ class BSBLANClimate(
_attr_name = None
# Determine preset modes
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE | ClimateEntityFeature.PRESET_MODE
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.PRESET_MODE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_attr_preset_modes = PRESET_MODES
# Determine hvac modes
_attr_hvac_modes = HVAC_MODES
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self,
+1 -1
View File
@@ -98,6 +98,6 @@ class TurboJPEGSingleton:
TurboJPEGSingleton.__instance = TurboJPEG()
except Exception: # pylint: disable=broad-except
_LOGGER.exception(
"Error loading libturbojpeg; Cameras may impact HomeKit performance"
"Error loading libturbojpeg; Camera snapshot performance will be sub-optimal"
)
TurboJPEGSingleton.__instance = False
@@ -4,8 +4,11 @@ from __future__ import annotations
from collections.abc import Mapping
from typing import Any
from aioelectricitymaps import ElectricityMaps
from aioelectricitymaps.exceptions import ElectricityMapsError, InvalidToken
from aioelectricitymaps import (
ElectricityMaps,
ElectricityMapsError,
ElectricityMapsInvalidTokenError,
)
import voluptuous as vol
from homeassistant import config_entries
@@ -146,7 +149,7 @@ class ConfigFlow(config_entries.ConfigFlow, domain=DOMAIN):
try:
await fetch_latest_carbon_intensity(self.hass, em, data)
except InvalidToken:
except ElectricityMapsInvalidTokenError:
errors["base"] = "invalid_auth"
except ElectricityMapsError:
errors["base"] = "unknown"
@@ -4,9 +4,12 @@ from __future__ import annotations
from datetime import timedelta
import logging
from aioelectricitymaps import ElectricityMaps
from aioelectricitymaps.exceptions import ElectricityMapsError, InvalidToken
from aioelectricitymaps.models import CarbonIntensityResponse
from aioelectricitymaps import (
CarbonIntensityResponse,
ElectricityMaps,
ElectricityMapsError,
ElectricityMapsInvalidTokenError,
)
from homeassistant.config_entries import ConfigEntry
from homeassistant.core import HomeAssistant
@@ -43,7 +46,7 @@ class CO2SignalCoordinator(DataUpdateCoordinator[CarbonIntensityResponse]):
return await fetch_latest_carbon_intensity(
self.hass, self.client, self.config_entry.data
)
except InvalidToken as err:
except ElectricityMapsInvalidTokenError as err:
raise ConfigEntryAuthFailed from err
except ElectricityMapsError as err:
raise UpdateFailed(str(err)) from err
@@ -7,5 +7,5 @@
"integration_type": "service",
"iot_class": "cloud_polling",
"loggers": ["aioelectricitymaps"],
"requirements": ["aioelectricitymaps==0.2.0"]
"requirements": ["aioelectricitymaps==0.3.0"]
}
@@ -349,7 +349,7 @@ async def websocket_hass_agent_debug(
},
# Slot values that would be received by the intent
"slots": { # direct access to values
entity_key: entity.value
entity_key: entity.text or entity.value
for entity_key, entity in result.entities.items()
},
# Extra slot details, such as the originally matched text
@@ -1,4 +1,5 @@
"""Standard conversation implementation for Home Assistant."""
from __future__ import annotations
import asyncio
@@ -264,9 +265,11 @@ class DefaultAgent(AbstractConversationAgent):
_LOGGER.debug(
"Recognized intent '%s' for template '%s' but had unmatched: %s",
result.intent.name,
result.intent_sentence.text
if result.intent_sentence is not None
else "",
(
result.intent_sentence.text
if result.intent_sentence is not None
else ""
),
result.unmatched_entities_list,
)
error_response_type, error_response_args = _get_unmatched_response(result)
@@ -285,7 +288,8 @@ class DefaultAgent(AbstractConversationAgent):
# Slot values to pass to the intent
slots = {
entity.name: {"value": entity.value} for entity in result.entities_list
entity.name: {"value": entity.value, "text": entity.text or entity.value}
for entity in result.entities_list
}
try:
@@ -474,9 +478,11 @@ class DefaultAgent(AbstractConversationAgent):
for entity_name, entity_value in recognize_result.entities.items()
},
# First matched or unmatched state
"state": template.TemplateState(self.hass, state1)
if state1 is not None
else None,
"state": (
template.TemplateState(self.hass, state1)
if state1 is not None
else None
),
"query": {
# Entity states that matched the query (e.g, "on")
"matched": [
@@ -734,7 +740,7 @@ class DefaultAgent(AbstractConversationAgent):
if not entity:
# Default name
entity_names.append((state.name, state.name, context))
entity_names.append((state.name, state.entity_id, context))
continue
if entity.aliases:
@@ -742,10 +748,10 @@ class DefaultAgent(AbstractConversationAgent):
if not alias.strip():
continue
entity_names.append((alias, alias, context))
entity_names.append((alias, state.entity_id, context))
# Default name
entity_names.append((state.name, state.name, context))
entity_names.append((state.name, state.entity_id, context))
# Expose all areas
areas = ar.async_get(self.hass)
@@ -785,7 +791,7 @@ class DefaultAgent(AbstractConversationAgent):
if device_area is None:
return None
return {"area": device_area.id}
return {"area": {"value": device_area.id, "text": device_area.name}}
def _get_error_text(
self,
@@ -7,5 +7,5 @@
"integration_type": "system",
"iot_class": "local_push",
"quality_scale": "internal",
"requirements": ["hassil==1.6.0", "home-assistant-intents==2024.2.1"]
"requirements": ["hassil==1.6.1", "home-assistant-intents==2024.2.2"]
}
+6 -1
View File
@@ -100,6 +100,7 @@ class DeconzThermostat(DeconzDevice[Thermostat], ClimateEntity):
TYPE = DOMAIN
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, device: Thermostat, gateway: DeconzGateway) -> None:
"""Set up thermostat device."""
@@ -119,7 +120,11 @@ class DeconzThermostat(DeconzDevice[Thermostat], ClimateEntity):
HVAC_MODE_TO_DECONZ[item]: item for item in self._attr_hvac_modes
}
self._attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
self._attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
if device.fan_mode:
self._attr_supported_features |= ClimateEntityFeature.FAN_MODE
+4
View File
@@ -97,6 +97,7 @@ class DemoClimate(ClimateEntity):
_attr_name = None
_attr_should_poll = False
_attr_translation_key = "ubercool"
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self,
@@ -137,6 +138,9 @@ class DemoClimate(ClimateEntity):
self._attr_supported_features |= (
ClimateEntityFeature.TARGET_TEMPERATURE_RANGE
)
self._attr_supported_features |= (
ClimateEntityFeature.TURN_OFF | ClimateEntityFeature.TURN_ON
)
self._target_temperature = target_temperature
self._target_humidity = target_humidity
self._unit_of_measurement = unit_of_measurement
@@ -75,7 +75,7 @@ async def _validate_input(
rest_config = create_rest_config(
aiohttp_client.async_get_clientsession(hass),
device_id=device_id,
country=country,
alpha_2_country=country,
override_rest_url=rest_url,
)
@@ -266,6 +266,10 @@ class EcovacsConfigFlow(ConfigFlow, domain=DOMAIN):
# If not we will inform the user about the mismatch.
error = None
placeholders = None
# Convert the country to upper case as ISO 3166-1 alpha-2 country codes are upper case
user_input[CONF_COUNTRY] = user_input[CONF_COUNTRY].upper()
if len(user_input[CONF_COUNTRY]) != 2:
error = "invalid_country_length"
placeholders = {"countries_url": "https://www.iso.org/obp/ui/#search/code/"}
@@ -49,7 +49,7 @@ class EcovacsController:
create_rest_config(
aiohttp_client.async_get_clientsession(self._hass),
device_id=self._device_id,
country=country,
alpha_2_country=country,
override_rest_url=config.get(CONF_OVERRIDE_REST_URL),
),
config[CONF_USERNAME],
@@ -6,5 +6,5 @@
"documentation": "https://www.home-assistant.io/integrations/ecovacs",
"iot_class": "cloud_push",
"loggers": ["sleekxmppfs", "sucks", "deebot_client"],
"requirements": ["py-sucks==0.9.8", "deebot-client==5.0.0"]
"requirements": ["py-sucks==0.9.8", "deebot-client==5.1.0"]
}
@@ -47,13 +47,13 @@
"name": "Relocate"
},
"reset_lifespan_brush": {
"name": "Reset brush lifespan"
"name": "Reset main brush lifespan"
},
"reset_lifespan_filter": {
"name": "Reset filter lifespan"
},
"reset_lifespan_side_brush": {
"name": "Reset side brush lifespan"
"name": "Reset side brushes lifespan"
}
},
"image": {
@@ -79,13 +79,13 @@
}
},
"lifespan_brush": {
"name": "Brush lifespan"
"name": "Main brush lifespan"
},
"lifespan_filter": {
"name": "Filter lifespan"
},
"lifespan_side_brush": {
"name": "Side brush lifespan"
"name": "Side brushes lifespan"
},
"network_ip": {
"name": "IP address"
@@ -100,7 +100,7 @@
"name": "Area cleaned"
},
"stats_time": {
"name": "Time cleaned"
"name": "Cleaning duration"
},
"total_stats_area": {
"name": "Total area cleaned"
@@ -109,12 +109,12 @@
"name": "Total cleanings"
},
"total_stats_time": {
"name": "Total time cleaned"
"name": "Total cleaning duration"
}
},
"select": {
"water_amount": {
"name": "Water amount",
"name": "Water flow level",
"state": {
"high": "High",
"low": "Low",
@@ -137,7 +137,7 @@
"name": "Advanced mode"
},
"carpet_auto_fan_boost": {
"name": "Carpet auto fan speed boost"
"name": "Carpet auto-boost suction"
},
"clean_preference": {
"name": "Clean preference"
@@ -7,6 +7,6 @@
"integration_type": "device",
"iot_class": "local_polling",
"quality_scale": "platinum",
"requirements": ["elgato==5.1.1"],
"requirements": ["elgato==5.1.2"],
"zeroconf": ["_elg._tcp.local."]
}
@@ -35,8 +35,10 @@ class ConfigFlow(config_entries.ConfigFlow, domain=DOMAIN):
self._api_token = api_token = user_input[CONF_API_TOKEN]
client = Elvia(meter_value_token=api_token).meter_value()
try:
end_time = dt_util.utcnow()
results = await client.get_meter_values(
start_time=(dt_util.now() - timedelta(hours=1)).isoformat()
start_time=(end_time - timedelta(hours=1)).isoformat(),
end_time=end_time.isoformat(),
)
except ElviaError.AuthError as exception:
+37 -11
View File
@@ -4,7 +4,7 @@ from __future__ import annotations
from datetime import datetime, timedelta
from typing import TYPE_CHECKING, cast
from elvia import Elvia
from elvia import Elvia, error as ElviaError
from homeassistant.components.recorder.models import StatisticData, StatisticMetaData
from homeassistant.components.recorder.statistics import (
@@ -38,11 +38,18 @@ class ElviaImporter:
self.client = Elvia(meter_value_token=api_token).meter_value()
self.metering_point_id = metering_point_id
async def _fetch_hourly_data(self, since: datetime) -> list[MeterValueTimeSeries]:
async def _fetch_hourly_data(
self,
since: datetime,
until: datetime,
) -> list[MeterValueTimeSeries]:
"""Fetch hourly data."""
LOGGER.debug("Fetching hourly data since %s", since)
start_time = since.isoformat()
end_time = until.isoformat()
LOGGER.debug("Fetching hourly data %s - %s", start_time, end_time)
all_data = await self.client.get_meter_values(
start_time=since.isoformat(),
start_time=start_time,
end_time=end_time,
metering_point_ids=[self.metering_point_id],
)
return all_data["meteringpoints"][0]["metervalue"]["timeSeries"]
@@ -61,18 +68,37 @@ class ElviaImporter:
)
if not last_stats:
# First time we insert 1 years of data (if available)
hourly_data = await self._fetch_hourly_data(
since=dt_util.now() - timedelta(days=365)
)
# First time we insert 3 years of data (if available)
hourly_data: list[MeterValueTimeSeries] = []
until = dt_util.utcnow()
for year in (3, 2, 1):
try:
year_hours = await self._fetch_hourly_data(
since=until - timedelta(days=365 * year),
until=until - timedelta(days=365 * (year - 1)),
)
except ElviaError.ElviaException:
# This will raise if the contract have no data for the
# year, we can safely ignore this
continue
hourly_data.extend(year_hours)
if hourly_data is None or len(hourly_data) == 0:
LOGGER.error("No data available for the metering point")
return
last_stats_time = None
_sum = 0.0
else:
hourly_data = await self._fetch_hourly_data(
since=dt_util.utc_from_timestamp(last_stats[statistic_id][0]["end"])
)
try:
hourly_data = await self._fetch_hourly_data(
since=dt_util.utc_from_timestamp(
last_stats[statistic_id][0]["end"]
),
until=dt_util.utcnow(),
)
except ElviaError.ElviaException as err:
LOGGER.error("Error fetching data: %s", err)
return
if (
hourly_data is None
@@ -352,7 +352,6 @@ class ESPHomeManager:
if self.voice_assistant_udp_server is not None:
_LOGGER.warning("Voice assistant UDP server was not stopped")
self.voice_assistant_udp_server.stop()
self.voice_assistant_udp_server.close()
self.voice_assistant_udp_server = None
hass = self.hass
@@ -1,4 +1,5 @@
"""ESPHome voice assistant support."""
from __future__ import annotations
import asyncio
@@ -67,7 +68,7 @@ class VoiceAssistantUDPServer(asyncio.DatagramProtocol):
"""Receive UDP packets and forward them to the voice assistant."""
started = False
stopped = False
stop_requested = False
transport: asyncio.DatagramTransport | None = None
remote_addr: tuple[str, int] | None = None
@@ -92,6 +93,11 @@ class VoiceAssistantUDPServer(asyncio.DatagramProtocol):
self._tts_done = asyncio.Event()
self._tts_task: asyncio.Task | None = None
@property
def is_running(self) -> bool:
"""True if the the UDP server is started and hasn't been asked to stop."""
return self.started and (not self.stop_requested)
async def start_server(self) -> int:
"""Start accepting connections."""
@@ -99,7 +105,7 @@ class VoiceAssistantUDPServer(asyncio.DatagramProtocol):
"""Accept connection."""
if self.started:
raise RuntimeError("Can only start once")
if self.stopped:
if self.stop_requested:
raise RuntimeError("No longer accepting connections")
self.started = True
@@ -124,7 +130,7 @@ class VoiceAssistantUDPServer(asyncio.DatagramProtocol):
@callback
def datagram_received(self, data: bytes, addr: tuple[str, int]) -> None:
"""Handle incoming UDP packet."""
if not self.started or self.stopped:
if not self.is_running:
return
if self.remote_addr is None:
self.remote_addr = addr
@@ -142,19 +148,19 @@ class VoiceAssistantUDPServer(asyncio.DatagramProtocol):
def stop(self) -> None:
"""Stop the receiver."""
self.queue.put_nowait(b"")
self.started = False
self.stopped = True
self.close()
def close(self) -> None:
"""Close the receiver."""
self.started = False
self.stopped = True
self.stop_requested = True
if self.transport is not None:
self.transport.close()
async def _iterate_packets(self) -> AsyncIterable[bytes]:
"""Iterate over incoming packets."""
if not self.started or self.stopped:
if not self.is_running:
raise RuntimeError("Not running")
while data := await self.queue.get():
@@ -303,8 +309,11 @@ class VoiceAssistantUDPServer(asyncio.DatagramProtocol):
async def _send_tts(self, media_id: str) -> None:
"""Send TTS audio to device via UDP."""
# Always send stream start/end events
self.handle_event(VoiceAssistantEventType.VOICE_ASSISTANT_TTS_STREAM_START, {})
try:
if self.transport is None:
if (not self.is_running) or (self.transport is None):
return
extension, data = await tts.async_get_media_source_audio(
@@ -337,15 +346,11 @@ class VoiceAssistantUDPServer(asyncio.DatagramProtocol):
_LOGGER.debug("Sending %d bytes of audio", audio_bytes_size)
self.handle_event(
VoiceAssistantEventType.VOICE_ASSISTANT_TTS_STREAM_START, {}
)
bytes_per_sample = stt.AudioBitRates.BITRATE_16 // 8
sample_offset = 0
samples_left = audio_bytes_size // bytes_per_sample
while samples_left > 0:
while (samples_left > 0) and self.is_running:
bytes_offset = sample_offset * bytes_per_sample
chunk: bytes = audio_bytes[bytes_offset : bytes_offset + 1024]
samples_in_chunk = len(chunk) // bytes_per_sample
+8 -1
View File
@@ -156,6 +156,7 @@ class EvoClimateEntity(EvoDevice, ClimateEntity):
"""Base for an evohome Climate device."""
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
@property
def hvac_modes(self) -> list[HVACMode]:
@@ -190,7 +191,10 @@ class EvoZone(EvoChild, EvoClimateEntity):
]
self._attr_supported_features = (
ClimateEntityFeature.PRESET_MODE | ClimateEntityFeature.TARGET_TEMPERATURE
ClimateEntityFeature.PRESET_MODE
| ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
async def async_zone_svc_request(self, service: str, data: dict[str, Any]) -> None:
@@ -372,6 +376,9 @@ class EvoController(EvoClimateEntity):
]
if self._attr_preset_modes:
self._attr_supported_features = ClimateEntityFeature.PRESET_MODE
self._attr_supported_features |= (
ClimateEntityFeature.TURN_OFF | ClimateEntityFeature.TURN_ON
)
async def async_tcs_svc_request(self, service: str, data: dict[str, Any]) -> None:
"""Process a service request (system mode) for a controller.
@@ -126,6 +126,8 @@ async def async_setup_entry(
class FibaroThermostat(FibaroDevice, ClimateEntity):
"""Representation of a Fibaro Thermostat."""
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, fibaro_device: DeviceModel) -> None:
"""Initialize the Fibaro device."""
super().__init__(fibaro_device)
@@ -209,6 +211,11 @@ class FibaroThermostat(FibaroDevice, ClimateEntity):
if mode in OPMODES_PRESET:
self._attr_preset_modes.append(OPMODES_PRESET[mode])
if HVACMode.OFF in self._attr_hvac_modes and len(self._attr_hvac_modes) > 1:
self._attr_supported_features |= (
ClimateEntityFeature.TURN_OFF | ClimateEntityFeature.TURN_ON
)
async def async_added_to_hass(self) -> None:
"""Call when entity is added to hass."""
_LOGGER.debug(
@@ -69,6 +69,7 @@ class Flexit(ClimateEntity):
ClimateEntityFeature.TARGET_TEMPERATURE | ClimateEntityFeature.FAN_MODE
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, hub: ModbusHub, modbus_slave: int | None, name: str | None
@@ -62,13 +62,17 @@ class FlexitClimateEntity(FlexitEntity, ClimateEntity):
]
_attr_supported_features = (
ClimateEntityFeature.PRESET_MODE | ClimateEntityFeature.TARGET_TEMPERATURE
ClimateEntityFeature.PRESET_MODE
| ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_attr_target_temperature_step = PRECISION_HALVES
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_max_temp = MAX_TEMP
_attr_min_temp = MIN_TEMP
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, coordinator: FlexitCoordinator) -> None:
"""Initialize the Flexit unit."""
@@ -20,5 +20,5 @@
"documentation": "https://www.home-assistant.io/integrations/frontend",
"integration_type": "system",
"quality_scale": "internal",
"requirements": ["home-assistant-frontend==20240131.0"]
"requirements": ["home-assistant-frontend==20240202.0"]
}
@@ -139,6 +139,7 @@ class HomeKitBaseClimateEntity(HomeKitEntity, ClimateEntity):
"""The base HomeKit Controller climate entity."""
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
@callback
def _async_reconfigure(self) -> None:
@@ -14,6 +14,6 @@
"documentation": "https://www.home-assistant.io/integrations/homekit_controller",
"iot_class": "local_push",
"loggers": ["aiohomekit", "commentjson"],
"requirements": ["aiohomekit==3.1.3"],
"requirements": ["aiohomekit==3.1.4"],
"zeroconf": ["_hap._tcp.local.", "_hap._udp.local."]
}
+10 -5
View File
@@ -8,7 +8,10 @@ from homeassistant.config_entries import ConfigEntry
from homeassistant.const import CONF_PASSWORD, CONF_USERNAME, Platform
from homeassistant.core import HomeAssistant, callback
from homeassistant.exceptions import ConfigEntryAuthFailed, ConfigEntryNotReady
from homeassistant.helpers.aiohttp_client import async_get_clientsession
from homeassistant.helpers.aiohttp_client import (
async_create_clientsession,
async_get_clientsession,
)
from .const import (
_LOGGER,
@@ -48,9 +51,12 @@ async def async_setup_entry(hass: HomeAssistant, config_entry: ConfigEntry) -> b
username = config_entry.data[CONF_USERNAME]
password = config_entry.data[CONF_PASSWORD]
client = aiosomecomfort.AIOSomeComfort(
username, password, session=async_get_clientsession(hass)
)
if len(hass.config_entries.async_entries(DOMAIN)) > 1:
session = async_create_clientsession(hass)
else:
session = async_get_clientsession(hass)
client = aiosomecomfort.AIOSomeComfort(username, password, session=session)
try:
await client.login()
await client.discover()
@@ -76,7 +82,6 @@ async def async_setup_entry(hass: HomeAssistant, config_entry: ConfigEntry) -> b
if len(devices) == 0:
_LOGGER.debug("No devices found")
return False
data = HoneywellData(config_entry.entry_id, client, devices)
hass.data.setdefault(DOMAIN, {})[config_entry.entry_id] = data
await hass.config_entries.async_forward_entry_setups(config_entry, PLATFORMS)
+6 -1
View File
@@ -134,12 +134,17 @@ class KNXClimate(KnxEntity, ClimateEntity):
_device: XknxClimate
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, xknx: XKNX, config: ConfigType) -> None:
"""Initialize of a KNX climate device."""
super().__init__(_create_climate(xknx, config))
self._attr_entity_category = config.get(CONF_ENTITY_CATEGORY)
self._attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
self._attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE | ClimateEntityFeature.TURN_ON
)
if self._device.supports_on_off:
self._attr_supported_features |= ClimateEntityFeature.TURN_OFF
if self.preset_modes:
self._attr_supported_features |= ClimateEntityFeature.PRESET_MODE
self._attr_target_temperature_step = self._device.temperature_step
+1 -1
View File
@@ -42,7 +42,7 @@ async def async_setup_entry(
lights = []
for area_name, device in entry_data.lights:
if device.type == "CEILING_FAN_TYPE2":
if device.type == "CEILING_FAN_TYPE":
# If this is a fan, check to see if this entity already exists.
# If not, do not create a new one.
entity_id = ent_reg.async_get_entity_id(
@@ -5,5 +5,5 @@
"documentation": "https://www.home-assistant.io/integrations/matrix",
"iot_class": "cloud_push",
"loggers": ["matrix_client"],
"requirements": ["matrix-nio==0.22.1", "Pillow==10.2.0"]
"requirements": ["matrix-nio==0.24.0", "Pillow==10.2.0"]
}
+8 -4
View File
@@ -73,11 +73,8 @@ class MatterClimate(MatterEntity, ClimateEntity):
"""Representation of a Matter climate entity."""
_attr_temperature_unit: str = UnitOfTemperature.CELSIUS
_attr_supported_features: ClimateEntityFeature = (
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TARGET_TEMPERATURE_RANGE
)
_attr_hvac_mode: HVACMode = HVACMode.OFF
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self,
@@ -99,6 +96,13 @@ class MatterClimate(MatterEntity, ClimateEntity):
self._attr_hvac_modes.append(HVACMode.COOL)
if feature_map & ThermostatFeature.kAutoMode:
self._attr_hvac_modes.append(HVACMode.HEAT_COOL)
self._attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TARGET_TEMPERATURE_RANGE
| ClimateEntityFeature.TURN_OFF
)
if any(mode for mode in self.hvac_modes if mode != HVACMode.OFF):
self._attr_supported_features |= ClimateEntityFeature.TURN_ON
async def async_set_temperature(self, **kwargs: Any) -> None:
"""Set new target temperature."""
+5 -1
View File
@@ -68,8 +68,12 @@ class MaxCubeClimate(ClimateEntity):
_attr_hvac_modes = [HVACMode.OFF, HVACMode.AUTO, HVACMode.HEAT]
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE | ClimateEntityFeature.PRESET_MODE
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.PRESET_MODE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, handler, device):
"""Initialize MAX! Cube ClimateEntity."""
@@ -114,6 +114,7 @@ class MelCloudClimate(ClimateEntity):
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_has_entity_name = True
_attr_name = None
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, device: MelCloudDevice) -> None:
"""Initialize the climate."""
@@ -137,6 +138,8 @@ class AtaDeviceClimate(MelCloudClimate):
ClimateEntityFeature.FAN_MODE
| ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.SWING_MODE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
def __init__(self, device: MelCloudDevice, ata_device: AtaDevice) -> None:
+5 -1
View File
@@ -57,9 +57,13 @@ class MelissaClimate(ClimateEntity):
_attr_hvac_modes = OP_MODES
_attr_supported_features = (
ClimateEntityFeature.FAN_MODE | ClimateEntityFeature.TARGET_TEMPERATURE
ClimateEntityFeature.FAN_MODE
| ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, api, serial_number, init_data):
"""Initialize the climate device."""
+1
View File
@@ -99,6 +99,7 @@ class MillHeater(CoordinatorEntity[MillDataUpdateCoordinator], ClimateEntity):
)
_attr_target_temperature_step = PRECISION_TENTHS
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, coordinator: MillDataUpdateCoordinator, heater: mill.Heater
@@ -182,7 +182,6 @@ class BaseStructPlatform(BasePlatform, RestoreEntity):
self._data_type = config[CONF_DATA_TYPE]
self._structure: str = config[CONF_STRUCTURE]
self._scale = config[CONF_SCALE]
self._precision = config.get(CONF_PRECISION, 2)
self._offset = config[CONF_OFFSET]
self._slave_count = config.get(CONF_SLAVE_COUNT, None) or config.get(
CONF_VIRTUAL_COUNT, 0
@@ -196,11 +195,10 @@ class BaseStructPlatform(BasePlatform, RestoreEntity):
DataType.UINT32,
DataType.UINT64,
)
if self._value_is_int:
if self._min_value:
self._min_value = round(self._min_value)
if self._max_value:
self._max_value = round(self._max_value)
if not self._value_is_int:
self._precision = config.get(CONF_PRECISION, 2)
else:
self._precision = config.get(CONF_PRECISION, 0)
def _swap_registers(self, registers: list[int], slave_count: int) -> list[int]:
"""Do swap as needed."""
@@ -235,13 +233,13 @@ class BaseStructPlatform(BasePlatform, RestoreEntity):
return None
val: float | int = self._scale * entry + self._offset
if self._min_value is not None and val < self._min_value:
return str(self._min_value)
val = self._min_value
if self._max_value is not None and val > self._max_value:
return str(self._max_value)
val = self._max_value
if self._zero_suppress is not None and abs(val) <= self._zero_suppress:
return "0"
if self._precision == 0 or self._value_is_int:
return str(int(round(val, 0)))
if self._precision == 0:
return str(round(val))
return f"{float(val):.{self._precision}f}"
def unpack_structure_result(self, registers: list[int]) -> str | None:
+6 -1
View File
@@ -97,7 +97,12 @@ async def async_setup_platform(
class ModbusThermostat(BaseStructPlatform, RestoreEntity, ClimateEntity):
"""Representation of a Modbus Thermostat."""
_attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self,
@@ -46,6 +46,7 @@ class Alpha2Climate(CoordinatorEntity[Alpha2BaseCoordinator], ClimateEntity):
_attr_hvac_modes = [HVACMode.HEAT, HVACMode.COOL]
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_preset_modes = [PRESET_AUTO, PRESET_DAY, PRESET_NIGHT]
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, coordinator: Alpha2BaseCoordinator, heat_area_id: str) -> None:
"""Initialize Alpha2 ClimateEntity."""
+1
View File
@@ -610,6 +610,7 @@ class MqttClimate(MqttTemperatureControlEntity, ClimateEntity):
_attributes_extra_blocked = MQTT_CLIMATE_ATTRIBUTES_BLOCKED
_attr_target_temperature_low: float | None = None
_attr_target_temperature_high: float | None = None
_enable_turn_on_off_backwards_compatibility = False
@staticmethod
def config_schema() -> vol.Schema:
@@ -70,11 +70,12 @@ class MySensorsHVAC(mysensors.device.MySensorsChildEntity, ClimateEntity):
"""Representation of a MySensors HVAC."""
_attr_hvac_modes = OPERATION_LIST
_enable_turn_on_off_backwards_compatibility = False
@property
def supported_features(self) -> ClimateEntityFeature:
"""Return the list of supported features."""
features = ClimateEntityFeature(0)
features = ClimateEntityFeature.TURN_OFF | ClimateEntityFeature.TURN_ON
set_req = self.gateway.const.SetReq
if set_req.V_HVAC_SPEED in self._values:
features = features | ClimateEntityFeature.FAN_MODE
+2 -1
View File
@@ -100,6 +100,7 @@ class ThermostatEntity(ClimateEntity):
_attr_has_entity_name = True
_attr_should_poll = False
_attr_name = None
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, device: Device) -> None:
"""Initialize ThermostatEntity."""
@@ -246,7 +247,7 @@ class ThermostatEntity(ClimateEntity):
def _get_supported_features(self) -> ClimateEntityFeature:
"""Compute the bitmap of supported features from the current state."""
features = ClimateEntityFeature(0)
features = ClimateEntityFeature.TURN_OFF | ClimateEntityFeature.TURN_ON
if HVACMode.HEAT_COOL in self.hvac_modes:
features |= ClimateEntityFeature.TARGET_TEMPERATURE_RANGE
if HVACMode.HEAT in self.hvac_modes or HVACMode.COOL in self.hvac_modes:
@@ -190,6 +190,7 @@ class NetatmoThermostat(NetatmoBaseEntity, ClimateEntity):
_attr_supported_features = SUPPORT_FLAGS
_attr_target_temperature_step = PRECISION_HALVES
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, netatmo_device: NetatmoRoom) -> None:
"""Initialize the sensor."""
@@ -153,6 +153,7 @@ class NexiaZone(NexiaThermostatZoneEntity, ClimateEntity):
"""Provides Nexia Climate support."""
_attr_name = None
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, coordinator: NexiaDataUpdateCoordinator, zone: NexiaThermostatZone
@@ -72,6 +72,7 @@ class NibeClimateEntity(CoordinatorEntity[Coordinator], ClimateEntity):
_attr_target_temperature_step = 0.5
_attr_max_temp = 35.0
_attr_min_temp = 5.0
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self,
@@ -81,6 +81,7 @@ class NoboZone(ClimateEntity):
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_target_temperature_step = 1
# Need to poll to get preset change when in HVACMode.AUTO, so can't set _attr_should_poll = False
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, zone_id, hub: nobo, override_type) -> None:
"""Initialize the climate device."""
@@ -78,6 +78,7 @@ class NuHeatThermostat(CoordinatorEntity, ClimateEntity):
_attr_has_entity_name = True
_attr_name = None
_attr_preset_modes = PRESET_MODES
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, coordinator, thermostat, temperature_unit):
"""Initialize the thermostat."""
+6 -1
View File
@@ -66,8 +66,13 @@ class ThermostatDevice(ClimateEntity):
"""Interface class for the oemthermostat module."""
_attr_hvac_modes = SUPPORT_HVAC
_attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, thermostat, name):
"""Initialize the device."""
@@ -84,6 +84,7 @@ class OpenThermClimate(ClimateEntity):
_away_state_a = False
_away_state_b = False
_current_operation: HVACAction | None = None
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, gw_dev, options):
"""Initialize the device."""
@@ -53,6 +53,7 @@ class AtlanticElectricalHeater(OverkizEntity, ClimateEntity):
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_translation_key = DOMAIN
_enable_turn_on_off_backwards_compatibility = False
@property
def hvac_mode(self) -> HVACMode:
@@ -75,6 +75,7 @@ class AtlanticElectricalHeaterWithAdjustableTemperatureSetpoint(
| ClimateEntityFeature.TURN_ON
)
_attr_translation_key = DOMAIN
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, device_url: str, coordinator: OverkizDataUpdateCoordinator
@@ -45,6 +45,7 @@ class AtlanticElectricalTowelDryer(OverkizEntity, ClimateEntity):
_attr_preset_modes = [*PRESET_MODE_TO_OVERKIZ]
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_translation_key = DOMAIN
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, device_url: str, coordinator: OverkizDataUpdateCoordinator
@@ -54,6 +54,7 @@ class AtlanticHeatRecoveryVentilation(OverkizEntity, ClimateEntity):
| ClimateEntityFeature.TURN_ON
)
_attr_translation_key = DOMAIN
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, device_url: str, coordinator: OverkizDataUpdateCoordinator
@@ -83,6 +83,7 @@ class AtlanticPassAPCHeatingZone(OverkizEntity, ClimateEntity):
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_translation_key = DOMAIN
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, device_url: str, coordinator: OverkizDataUpdateCoordinator
@@ -30,6 +30,7 @@ class AtlanticPassAPCZoneControl(OverkizEntity, ClimateEntity):
_attr_supported_features = (
ClimateEntityFeature.TURN_OFF | ClimateEntityFeature.TURN_ON
)
_enable_turn_on_off_backwards_compatibility = False
@property
def hvac_mode(self) -> HVACMode:
@@ -90,6 +90,7 @@ class HitachiAirToAirHeatPumpHLRRWIFI(OverkizEntity, ClimateEntity):
_attr_target_temperature_step = 1.0
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_translation_key = DOMAIN
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, device_url: str, coordinator: OverkizDataUpdateCoordinator
@@ -81,6 +81,7 @@ class SomfyHeatingTemperatureInterface(OverkizEntity, ClimateEntity):
# Both min and max temp values have been retrieved from the Somfy Application.
_attr_min_temp = 15.0
_attr_max_temp = 26.0
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, device_url: str, coordinator: OverkizDataUpdateCoordinator
@@ -64,6 +64,7 @@ class SomfyThermostat(OverkizEntity, ClimateEntity):
_attr_hvac_modes = [*HVAC_MODES_TO_OVERKIZ]
_attr_preset_modes = [*PRESET_MODES_TO_OVERKIZ]
_attr_translation_key = DOMAIN
_enable_turn_on_off_backwards_compatibility = False
# Both min and max temp values have been retrieved from the Somfy Application.
_attr_min_temp = 15.0
@@ -58,6 +58,7 @@ class ValveHeatingTemperatureInterface(OverkizEntity, ClimateEntity):
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_translation_key = DOMAIN
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, device_url: str, coordinator: OverkizDataUpdateCoordinator
@@ -60,6 +60,7 @@ class ProliphixThermostat(ClimateEntity):
_attr_precision = PRECISION_TENTHS
_attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
_attr_temperature_unit = UnitOfTemperature.FAHRENHEIT
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, pdp):
"""Initialize the thermostat."""
@@ -0,0 +1,49 @@
"""Diagnostics support for Proximity."""
from __future__ import annotations
from typing import Any
from homeassistant.components.device_tracker import ATTR_GPS, ATTR_IP, ATTR_MAC
from homeassistant.components.diagnostics import async_redact_data
from homeassistant.components.person import ATTR_USER_ID
from homeassistant.config_entries import ConfigEntry
from homeassistant.const import ATTR_LATITUDE, ATTR_LONGITUDE
from homeassistant.core import HomeAssistant
from .const import DOMAIN
from .coordinator import ProximityDataUpdateCoordinator
TO_REDACT = {
ATTR_GPS,
ATTR_IP,
ATTR_LATITUDE,
ATTR_LONGITUDE,
ATTR_MAC,
ATTR_USER_ID,
"context",
}
async def async_get_config_entry_diagnostics(
hass: HomeAssistant, entry: ConfigEntry
) -> dict[str, Any]:
"""Return diagnostics for a config entry."""
coordinator: ProximityDataUpdateCoordinator = hass.data[DOMAIN][entry.entry_id]
diag_data = {
"entry": entry.as_dict(),
}
tracked_states: dict[str, dict] = {}
for tracked_entity_id in coordinator.tracked_entities:
if (state := hass.states.get(tracked_entity_id)) is None:
continue
tracked_states[tracked_entity_id] = state.as_dict()
diag_data["data"] = {
"proximity": coordinator.data.proximity,
"entities": coordinator.data.entities,
"entity_mapping": coordinator.entity_mapping,
"tracked_states": async_redact_data(tracked_states, TO_REDACT),
}
return diag_data
@@ -106,6 +106,7 @@ class RadioThermostat(RadioThermostatEntity, ClimateEntity):
_attr_temperature_unit = UnitOfTemperature.FAHRENHEIT
_attr_precision = PRECISION_HALVES
_attr_name = None
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, coordinator: RadioThermUpdateCoordinator) -> None:
"""Initialize the thermostat."""
@@ -113,7 +114,10 @@ class RadioThermostat(RadioThermostatEntity, ClimateEntity):
self._attr_unique_id = self.init_data.mac
self._attr_fan_modes = CT30_FAN_OPERATION_LIST
self._attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE | ClimateEntityFeature.FAN_MODE
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.FAN_MODE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
if not isinstance(self.device, radiotherm.thermostat.CT80):
return
@@ -794,4 +794,6 @@ def purge_entity_data(
_LOGGER.debug("Purging entity data hasn't fully completed yet")
return False
_purge_old_entity_ids(instance, session)
return True
@@ -81,6 +81,7 @@ class SchluterThermostat(CoordinatorEntity, ClimateEntity):
_attr_hvac_modes = [HVACMode.HEAT]
_attr_supported_features = ClimateEntityFeature.TARGET_TEMPERATURE
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, coordinator, serial_number, api, session_id):
"""Initialize the thermostat."""
@@ -81,8 +81,12 @@ class ScreenLogicClimate(ScreenLogicPushEntity, ClimateEntity, RestoreEntity):
entity_description: ScreenLogicClimateDescription
_attr_hvac_modes = SUPPORTED_MODES
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE | ClimateEntityFeature.PRESET_MODE
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.PRESET_MODE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, coordinator, entity_description) -> None:
"""Initialize a ScreenLogic climate entity."""
@@ -191,6 +191,7 @@ class SensiboClimate(SensiboDeviceBaseEntity, ClimateEntity):
_attr_name = None
_attr_precision = PRECISION_TENTHS
_attr_translation_key = "climate_device"
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, coordinator: SensiboDataUpdateCoordinator, device_id: str
+1
View File
@@ -45,6 +45,7 @@ class SENZClimate(CoordinatorEntity, ClimateEntity):
_attr_min_temp = 5
_attr_has_entity_name = True
_attr_name = None
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self,
@@ -167,6 +167,7 @@ class BlockSleepingClimate(
)
_attr_target_temperature_step = SHTRV_01_TEMPERATURE_SETTINGS["step"]
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self,
@@ -448,6 +449,7 @@ class RpcClimate(ShellyRpcEntity, ClimateEntity):
)
_attr_target_temperature_step = RPC_THERMOSTAT_SETTINGS["step"]
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, coordinator: ShellyRpcCoordinator, id_: int) -> None:
"""Initialize."""
@@ -162,6 +162,8 @@ def get_capabilities(capabilities: Sequence[str]) -> Sequence[str] | None:
class SmartThingsThermostat(SmartThingsEntity, ClimateEntity):
"""Define a SmartThings climate entities."""
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, device):
"""Init the class."""
super().__init__(device)
@@ -343,6 +345,7 @@ class SmartThingsAirConditioner(SmartThingsEntity, ClimateEntity):
"""Define a SmartThings Air Conditioner."""
_hvac_modes: list[HVACMode]
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, device) -> None:
"""Init the class."""
@@ -67,6 +67,7 @@ class SmartTubThermostat(SmartTubEntity, ClimateEntity):
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_preset_modes = list(PRESET_MODES.values())
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, coordinator, spa):
"""Initialize the entity."""
+5 -1
View File
@@ -76,6 +76,10 @@ class SonosEntity(Entity):
@property
def device_info(self) -> DeviceInfo:
"""Return information about the device."""
suggested_area: str | None = None
if not self.speaker.battery_info:
# Only set suggested area for non-portable devices
suggested_area = self.speaker.zone_name
return DeviceInfo(
identifiers={(DOMAIN, self.soco.uid)},
name=self.speaker.zone_name,
@@ -86,7 +90,7 @@ class SonosEntity(Entity):
(dr.CONNECTION_UPNP, f"uuid:{self.speaker.uid}"),
},
manufacturer="Sonos",
suggested_area=self.speaker.zone_name,
suggested_area=suggested_area,
configuration_url=f"http://{self.soco.ip_address}:1400/support/review",
)
@@ -73,9 +73,13 @@ class StiebelEltron(ClimateEntity):
_attr_hvac_modes = SUPPORT_HVAC
_attr_supported_features = (
ClimateEntityFeature.TARGET_TEMPERATURE | ClimateEntityFeature.PRESET_MODE
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.PRESET_MODE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, name, ste_data):
"""Initialize the unit."""
@@ -89,7 +89,9 @@ async def async_migrate_entry(
device_registry, config_entry_id=config_entry.entry_id
)
for dev in device_entries:
device_registry.async_remove_device(dev.id)
device_registry.async_update_device(
dev.id, remove_config_entry_id=config_entry.entry_id
)
entity_id = entity_registry.async_get_entity_id(
Platform.SENSOR, DOMAIN, "None_departure"
@@ -105,12 +107,13 @@ async def async_migrate_entry(
)
# Set a valid unique id for config entries
config_entry.unique_id = new_unique_id
config_entry.minor_version = 2
hass.config_entries.async_update_entry(config_entry)
hass.config_entries.async_update_entry(config_entry, unique_id=new_unique_id)
_LOGGER.debug(
"Migration to minor version %s successful", config_entry.minor_version
"Migration to version %s.%s successful",
config_entry.version,
config_entry.minor_version,
)
return True
@@ -80,6 +80,7 @@ class SwitchBotCloudAirConditionner(SwitchBotCloudEntity, ClimateEntity):
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_attr_target_temperature = 21
_attr_name = None
_enable_turn_on_off_backwards_compatibility = False
async def _do_send_command(
self,
+5 -1
View File
@@ -131,7 +131,10 @@ def create_climate_entity(tado, name: str, zone_id: int, device_info: dict):
zone_type = capabilities["type"]
support_flags = (
ClimateEntityFeature.PRESET_MODE | ClimateEntityFeature.TARGET_TEMPERATURE
ClimateEntityFeature.PRESET_MODE
| ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
supported_hvac_modes = [
TADO_TO_HA_HVAC_MODE_MAP[CONST_MODE_OFF],
@@ -221,6 +224,7 @@ class TadoClimate(TadoZoneEntity, ClimateEntity):
_attr_name = None
_attr_translation_key = DOMAIN
_available = False
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self,
@@ -1,6 +1,7 @@
"""Diagnostics support for Tankerkoenig."""
from __future__ import annotations
from dataclasses import asdict
from typing import Any
from homeassistant.components.diagnostics import async_redact_data
@@ -27,6 +28,9 @@ async def async_get_config_entry_diagnostics(
diag_data = {
"entry": async_redact_data(entry.as_dict(), TO_REDACT),
"data": coordinator.data,
"data": {
station_id: asdict(price_info)
for station_id, price_info in coordinator.data.items()
},
}
return diag_data
@@ -6,5 +6,5 @@
"documentation": "https://www.home-assistant.io/integrations/tankerkoenig",
"iot_class": "cloud_polling",
"loggers": ["aiotankerkoenig"],
"requirements": ["aiotankerkoenig==0.2.0"]
"requirements": ["aiotankerkoenig==0.3.0"]
}
@@ -75,6 +75,7 @@
"safety": "[%key:component::binary_sensor::entity_component::safety::name%]",
"smoke": "[%key:component::binary_sensor::entity_component::smoke::name%]",
"sound": "[%key:component::binary_sensor::entity_component::sound::name%]",
"tamper": "[%key:component::binary_sensor::entity_component::tamper::name%]",
"update": "[%key:component::binary_sensor::entity_component::update::name%]",
"vibration": "[%key:component::binary_sensor::entity_component::vibration::name%]",
"window": "[%key:component::binary_sensor::entity_component::window::name%]"
@@ -127,6 +128,7 @@
"volatile_organic_compounds_parts": "[%key:component::sensor::entity_component::volatile_organic_compounds::name%]",
"voltage": "[%key:component::sensor::entity_component::voltage::name%]",
"volume": "[%key:component::sensor::entity_component::volume::name%]",
"volume_flow_rate": "[%key:component::sensor::entity_component::volume_flow_rate::name%]",
"volume_storage": "[%key:component::sensor::entity_component::volume_storage::name%]",
"water": "[%key:component::sensor::entity_component::water::name%]",
"weight": "[%key:component::sensor::entity_component::weight::name%]",
@@ -45,6 +45,7 @@ class TeslemetryClimateEntity(TeslemetryVehicleEntity, ClimateEntity):
| ClimateEntityFeature.PRESET_MODE
)
_attr_preset_modes = ["off", "keep", "dog", "camp"]
_enable_turn_on_off_backwards_compatibility = False
@property
def hvac_mode(self) -> HVACMode | None:
@@ -56,6 +56,7 @@ class TessieClimateEntity(TessieEntity, ClimateEntity):
TessieClimateKeeper.DOG,
TessieClimateKeeper.CAMP,
]
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self,
@@ -83,8 +83,11 @@ class TfiacClimate(ClimateEntity):
ClimateEntityFeature.FAN_MODE
| ClimateEntityFeature.SWING_MODE
| ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_attr_temperature_unit = UnitOfTemperature.FAHRENHEIT
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, hass, client):
"""Init class."""
+1
View File
@@ -58,6 +58,7 @@ class SaunaClimate(ToloSaunaCoordinatorEntity, ClimateEntity):
)
_attr_target_temperature_step = 1
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, coordinator: ToloSaunaUpdateCoordinator, entry: ConfigEntry
+1
View File
@@ -51,6 +51,7 @@ class ToonThermostatDevice(ToonDisplayDeviceEntity, ClimateEntity):
ClimateEntityFeature.TARGET_TEMPERATURE | ClimateEntityFeature.PRESET_MODE
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self,
@@ -69,6 +69,7 @@ class Touchline(ClimateEntity):
ClimateEntityFeature.TARGET_TEMPERATURE | ClimateEntityFeature.PRESET_MODE
)
_attr_temperature_unit = UnitOfTemperature.CELSIUS
_enable_turn_on_off_backwards_compatibility = False
def __init__(self, touchline_thermostat):
"""Initialize the Touchline device."""
+66 -2
View File
@@ -156,6 +156,10 @@
"hostname": "k[lps]*",
"macaddress": "54AF97*"
},
{
"hostname": "l[59]*",
"macaddress": "54AF97*"
},
{
"hostname": "k[lps]*",
"macaddress": "AC15A2*"
@@ -177,21 +181,41 @@
"macaddress": "5CE931*"
},
{
"hostname": "l5*",
"hostname": "l[59]*",
"macaddress": "3C52A1*"
},
{
"hostname": "l5*",
"macaddress": "5C628B*"
},
{
"hostname": "tp*",
"macaddress": "5C628B*"
},
{
"hostname": "p1*",
"macaddress": "482254*"
},
{
"hostname": "s5*",
"macaddress": "482254*"
},
{
"hostname": "p1*",
"macaddress": "30DE4B*"
},
{
"hostname": "p1*",
"macaddress": "3C52A1*"
},
{
"hostname": "tp*",
"macaddress": "3C52A1*"
},
{
"hostname": "s5*",
"macaddress": "3C52A1*"
},
{
"hostname": "l9*",
"macaddress": "A842A1*"
@@ -199,11 +223,51 @@
{
"hostname": "l9*",
"macaddress": "3460F9*"
},
{
"hostname": "hs*",
"macaddress": "704F57*"
},
{
"hostname": "k[lps]*",
"macaddress": "74DA88*"
},
{
"hostname": "p3*",
"macaddress": "788CB5*"
},
{
"hostname": "p1*",
"macaddress": "CC32E5*"
},
{
"hostname": "k[lps]*",
"macaddress": "CC32E5*"
},
{
"hostname": "hs*",
"macaddress": "CC32E5*"
},
{
"hostname": "k[lps]*",
"macaddress": "D80D17*"
},
{
"hostname": "k[lps]*",
"macaddress": "D84732*"
},
{
"hostname": "p1*",
"macaddress": "F0A731*"
},
{
"hostname": "l9*",
"macaddress": "F0A731*"
}
],
"documentation": "https://www.home-assistant.io/integrations/tplink",
"iot_class": "local_polling",
"loggers": ["kasa"],
"quality_scale": "platinum",
"requirements": ["python-kasa[speedups]==0.6.2"]
"requirements": ["python-kasa[speedups]==0.6.2.1"]
}
@@ -5,7 +5,7 @@
"config_flow": true,
"dependencies": ["webhook"],
"documentation": "https://www.home-assistant.io/integrations/traccar",
"iot_class": "local_polling",
"iot_class": "cloud_push",
"loggers": ["pytraccar"],
"requirements": ["pytraccar==2.0.0", "stringcase==1.2.0"]
}
@@ -41,6 +41,7 @@ class VelbusClimate(VelbusEntity, ClimateEntity):
_attr_hvac_mode = HVACMode.HEAT
_attr_hvac_modes = [HVACMode.HEAT]
_attr_preset_modes = list(PRESET_MODES)
_enable_turn_on_off_backwards_compatibility = False
@property
def target_temperature(self) -> float | None:
@@ -108,6 +108,7 @@ class VenstarThermostat(VenstarEntity, ClimateEntity):
_attr_hvac_modes = [HVACMode.HEAT, HVACMode.COOL, HVACMode.OFF, HVACMode.AUTO]
_attr_precision = PRECISION_HALVES
_attr_name = None
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self,
@@ -130,6 +131,8 @@ class VenstarThermostat(VenstarEntity, ClimateEntity):
ClimateEntityFeature.TARGET_TEMPERATURE
| ClimateEntityFeature.FAN_MODE
| ClimateEntityFeature.PRESET_MODE
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
if self._client.mode == self._client.MODE_AUTO:
+1
View File
@@ -53,6 +53,7 @@ class VeraThermostat(VeraDevice[veraApi.VeraThermostat], ClimateEntity):
| ClimateEntityFeature.TURN_OFF
| ClimateEntityFeature.TURN_ON
)
_enable_turn_on_off_backwards_compatibility = False
def __init__(
self, vera_device: veraApi.VeraThermostat, controller_data: ControllerData
@@ -58,7 +58,6 @@ class VerisureDoorWindowSensor(
area = self.coordinator.data["door_window"][self.serial_number]["area"]
return DeviceInfo(
name=area,
suggested_area=area,
manufacturer="Verisure",
model="Shock Sensor Detector",
identifiers={(DOMAIN, self.serial_number)},
@@ -71,7 +71,6 @@ class VerisureSmartcam(CoordinatorEntity[VerisureDataUpdateCoordinator], Camera)
area = self.coordinator.data["cameras"][self.serial_number]["device"]["area"]
return DeviceInfo(
name=area,
suggested_area=area,
manufacturer="Verisure",
model="SmartCam",
identifiers={(DOMAIN, self.serial_number)},

Some files were not shown because too many files have changed in this diff Show More