homeassistant 2025.11.0__py3-none-any.whl → 2025.11.0b2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- homeassistant/components/alexa_devices/manifest.json +1 -1
- homeassistant/components/alexa_devices/translations/bg.json +0 -13
- homeassistant/components/ambient_network/sensor.py +5 -5
- homeassistant/components/blink/translations/bg.json +1 -8
- homeassistant/components/brother/translations/bg.json +6 -0
- homeassistant/components/brother/translations/ca.json +5 -1
- homeassistant/components/brother/translations/cs.json +2 -2
- homeassistant/components/brother/translations/da.json +5 -1
- homeassistant/components/brother/translations/de.json +4 -4
- homeassistant/components/brother/translations/el.json +5 -1
- homeassistant/components/brother/translations/en-GB.json +4 -4
- homeassistant/components/brother/translations/en.json +4 -4
- homeassistant/components/brother/translations/es-419.json +5 -0
- homeassistant/components/brother/translations/es.json +2 -2
- homeassistant/components/brother/translations/et.json +2 -2
- homeassistant/components/brother/translations/fi.json +5 -1
- homeassistant/components/brother/translations/fr.json +5 -1
- homeassistant/components/brother/translations/ga.json +10 -2
- homeassistant/components/brother/translations/hu.json +5 -1
- homeassistant/components/brother/translations/id.json +5 -1
- homeassistant/components/brother/translations/it.json +5 -1
- homeassistant/components/brother/translations/ja.json +5 -1
- homeassistant/components/brother/translations/ko.json +5 -1
- homeassistant/components/brother/translations/lb.json +2 -1
- homeassistant/components/brother/translations/lt.json +2 -2
- homeassistant/components/brother/translations/nb.json +5 -1
- homeassistant/components/brother/translations/nl.json +5 -1
- homeassistant/components/brother/translations/pl.json +7 -3
- homeassistant/components/brother/translations/pt-BR.json +5 -1
- homeassistant/components/brother/translations/pt.json +10 -2
- homeassistant/components/brother/translations/ro.json +2 -1
- homeassistant/components/brother/translations/ru.json +5 -1
- homeassistant/components/brother/translations/sk.json +2 -2
- homeassistant/components/brother/translations/sl.json +10 -2
- homeassistant/components/brother/translations/sv.json +10 -2
- homeassistant/components/brother/translations/tr.json +5 -1
- homeassistant/components/brother/translations/uk.json +5 -1
- homeassistant/components/brother/translations/vi.json +5 -1
- homeassistant/components/brother/translations/zh-Hans.json +2 -2
- homeassistant/components/brother/translations/zh-Hant.json +4 -4
- homeassistant/components/bryant_evolution/translations/lt.json +0 -3
- homeassistant/components/control4/translations/es.json +1 -2
- homeassistant/components/cover/translations/es.json +7 -7
- homeassistant/components/daikin/translations/es.json +0 -1
- homeassistant/components/ecovacs/translations/es.json +0 -27
- homeassistant/components/ecovacs/translations/sr-Latn.json +0 -18
- homeassistant/components/enmax/__init__.py +1 -0
- homeassistant/components/enmax/manifest.json +6 -0
- homeassistant/components/esphome/__init__.py +3 -5
- homeassistant/components/esphome/translations/he.json +2 -2
- homeassistant/components/firefly_iii/translations/bg.json +0 -3
- homeassistant/components/foscam/manifest.json +1 -1
- homeassistant/components/frontend/__init__.py +1 -1
- homeassistant/components/frontend/manifest.json +1 -1
- homeassistant/components/google_sheets/translations/bg.json +0 -10
- homeassistant/components/google_sheets/translations/es.json +0 -9
- homeassistant/components/google_sheets/translations/sr-Latn.json +0 -14
- homeassistant/components/habitica/translations/es.json +0 -26
- homeassistant/components/hassio/issues.py +2 -0
- homeassistant/components/hassio/translations/es.json +0 -13
- homeassistant/components/holiday/manifest.json +1 -1
- homeassistant/components/homeassistant_connect_zbt2/config_flow.py +1 -18
- homeassistant/components/homeassistant_connect_zbt2/const.py +0 -58
- homeassistant/components/homeassistant_hardware/firmware_config_flow.py +0 -5
- homeassistant/components/homewizard/translations/es.json +2 -4
- homeassistant/components/http/__init__.py +2 -13
- homeassistant/components/http/strings.json +0 -4
- homeassistant/components/http/translations/de.json +0 -4
- homeassistant/components/http/translations/en-GB.json +0 -4
- homeassistant/components/http/translations/en.json +0 -4
- homeassistant/components/http/translations/es.json +0 -4
- homeassistant/components/http/translations/et.json +0 -4
- homeassistant/components/http/translations/lt.json +0 -4
- homeassistant/components/http/translations/sk.json +0 -4
- homeassistant/components/http/translations/zh-Hant.json +0 -4
- homeassistant/components/input_boolean/translations/cs.json +2 -2
- homeassistant/components/jewish_calendar/translations/es.json +0 -6
- homeassistant/components/knx/translations/bg.json +0 -93
- homeassistant/components/knx/translations/es.json +8 -39
- homeassistant/components/knx/translations/sr-Latn.json +1 -44
- homeassistant/components/lametric/translations/es.json +0 -1
- homeassistant/components/lg_thinq/sensor.py +0 -1
- homeassistant/components/litterrobot/manifest.json +1 -1
- homeassistant/components/london_underground/translations/he.json +0 -1
- homeassistant/components/matrix/translations/bg.json +1 -2
- homeassistant/components/matter/translations/bg.json +0 -7
- homeassistant/components/matter/translations/es.json +3 -26
- homeassistant/components/mcp/translations/es.json +0 -4
- homeassistant/components/mqtt/translations/es.json +4 -4
- homeassistant/components/mqtt/translations/he.json +2 -2
- homeassistant/components/nederlandse_spoorwegen/translations/bg.json +1 -2
- homeassistant/components/nextdns/translations/bg.json +1 -2
- homeassistant/components/nina/translations/bg.json +6 -0
- homeassistant/components/nina/translations/es.json +1 -40
- homeassistant/components/nina/translations/sr-Latn.json +0 -28
- homeassistant/components/nintendo_parental_controls/translations/bg.json +0 -19
- homeassistant/components/nuki/translations/es.json +0 -4
- homeassistant/components/octoprint/translations/es.json +0 -16
- homeassistant/components/oralb/translations/es.json +0 -1
- homeassistant/components/overkiz/translations/lt.json +1 -2
- homeassistant/components/plugwise/climate.py +26 -86
- homeassistant/components/plugwise/manifest.json +1 -1
- homeassistant/components/plugwise/strings.json +0 -3
- homeassistant/components/plugwise/translations/de.json +0 -3
- homeassistant/components/plugwise/translations/en-GB.json +0 -3
- homeassistant/components/plugwise/translations/en.json +0 -3
- homeassistant/components/plugwise/translations/es.json +0 -3
- homeassistant/components/plugwise/translations/et.json +0 -3
- homeassistant/components/plugwise/translations/lt.json +0 -3
- homeassistant/components/plugwise/translations/sk.json +0 -3
- homeassistant/components/plugwise/translations/zh-Hant.json +0 -3
- homeassistant/components/portainer/translations/bg.json +1 -8
- homeassistant/components/portainer/translations/sr-Latn.json +1 -3
- homeassistant/components/probe_plus/translations/es.json +0 -5
- homeassistant/components/ps4/translations/es.json +1 -9
- homeassistant/components/reolink/manifest.json +1 -1
- homeassistant/components/reolink/translations/cs.json +0 -1
- homeassistant/components/reolink/translations/en-GB.json +0 -1
- homeassistant/components/reolink/translations/es.json +0 -1
- homeassistant/components/reolink/translations/et.json +0 -1
- homeassistant/components/reolink/translations/lt.json +0 -1
- homeassistant/components/reolink/translations/pl.json +7 -8
- homeassistant/components/reolink/translations/sk.json +0 -1
- homeassistant/components/ruuvitag_ble/manifest.json +1 -1
- homeassistant/components/shelly/translations/bg.json +1 -2
- homeassistant/components/shelly/translations/es.json +3 -10
- homeassistant/components/slide_local/translations/es.json +1 -1
- homeassistant/components/smarttub/manifest.json +1 -1
- homeassistant/components/somfy_mylink/translations/es.json +3 -3
- homeassistant/components/soundtouch/__init__.py +1 -10
- homeassistant/components/sql/translations/es.json +0 -27
- homeassistant/components/sql/translations/sr-Latn.json +0 -9
- homeassistant/components/squeezebox/translations/es.json +0 -63
- homeassistant/components/{sunricher_dali → sunricher_dali_center}/__init__.py +2 -2
- homeassistant/components/{sunricher_dali → sunricher_dali_center}/config_flow.py +2 -2
- homeassistant/components/sunricher_dali_center/const.py +5 -0
- homeassistant/components/{sunricher_dali → sunricher_dali_center}/light.py +2 -2
- homeassistant/components/{sunricher_dali → sunricher_dali_center}/manifest.json +3 -3
- homeassistant/components/{sunricher_dali → sunricher_dali_center}/strings.json +6 -4
- homeassistant/components/sunricher_dali_center/translations/cs.json +29 -0
- homeassistant/components/{sunricher_dali → sunricher_dali_center}/translations/de.json +7 -5
- homeassistant/components/sunricher_dali_center/translations/el.json +11 -0
- homeassistant/components/{sunricher_dali → sunricher_dali_center}/translations/en-GB.json +6 -4
- homeassistant/components/{sunricher_dali → sunricher_dali_center}/translations/en.json +6 -4
- homeassistant/components/{sunricher_dali → sunricher_dali_center}/translations/es.json +6 -4
- homeassistant/components/sunricher_dali_center/translations/et.json +29 -0
- homeassistant/components/sunricher_dali_center/translations/ga.json +29 -0
- homeassistant/components/sunricher_dali_center/translations/he.json +11 -0
- homeassistant/components/sunricher_dali_center/translations/it.json +11 -0
- homeassistant/components/sunricher_dali_center/translations/lt.json +29 -0
- homeassistant/components/sunricher_dali_center/translations/nl.json +11 -0
- homeassistant/components/sunricher_dali_center/translations/pt.json +29 -0
- homeassistant/components/sunricher_dali_center/translations/sk.json +29 -0
- homeassistant/components/sunricher_dali_center/translations/sr-Latn.json +11 -0
- homeassistant/components/sunricher_dali_center/translations/zh-Hans.json +29 -0
- homeassistant/components/sunricher_dali_center/translations/zh-Hant.json +29 -0
- homeassistant/components/{sunricher_dali → sunricher_dali_center}/types.py +2 -2
- homeassistant/components/switch_as_x/translations/cs.json +1 -1
- homeassistant/components/switch_as_x/translations/es.json +4 -4
- homeassistant/components/system_bridge/translations/es.json +0 -1
- homeassistant/components/telegram_bot/translations/bg.json +0 -11
- homeassistant/components/telegram_bot/translations/es.json +7 -42
- homeassistant/components/template/translations/es.json +3 -11
- homeassistant/components/tesla_fleet/manifest.json +1 -1
- homeassistant/components/teslemetry/manifest.json +1 -1
- homeassistant/components/tessie/manifest.json +1 -1
- homeassistant/components/tessie/translations/es.json +0 -3
- homeassistant/components/transmission/translations/bg.json +0 -10
- homeassistant/components/usb/utils.py +23 -22
- homeassistant/components/vesync/humidifier.py +1 -3
- homeassistant/components/vesync/strings.json +0 -11
- homeassistant/components/vesync/translations/bg.json +0 -11
- homeassistant/components/vesync/translations/cs.json +0 -11
- homeassistant/components/vesync/translations/de.json +0 -11
- homeassistant/components/vesync/translations/en-GB.json +0 -11
- homeassistant/components/vesync/translations/en.json +0 -11
- homeassistant/components/vesync/translations/es.json +0 -11
- homeassistant/components/vesync/translations/et.json +0 -11
- homeassistant/components/vesync/translations/he.json +0 -11
- homeassistant/components/vesync/translations/lt.json +0 -11
- homeassistant/components/vesync/translations/sk.json +0 -11
- homeassistant/components/vesync/translations/zh-Hans.json +0 -11
- homeassistant/components/vesync/translations/zh-Hant.json +0 -11
- homeassistant/components/volvo/translations/bg.json +0 -5
- homeassistant/components/volvo/translations/cs.json +0 -5
- homeassistant/components/volvo/translations/en-GB.json +0 -5
- homeassistant/components/volvo/translations/es.json +0 -11
- homeassistant/components/volvo/translations/lt.json +0 -5
- homeassistant/components/volvo/translations/sk.json +0 -5
- homeassistant/components/whirlpool/translations/bg.json +0 -22
- homeassistant/components/whirlpool/translations/es.json +0 -81
- homeassistant/components/workday/manifest.json +1 -1
- homeassistant/components/xbox/translations/bg.json +0 -36
- homeassistant/components/xbox/translations/es.json +0 -21
- homeassistant/components/xbox/translations/sr-Latn.json +0 -1
- homeassistant/components/yardian/translations/bg.json +0 -7
- homeassistant/components/yardian/translations/es.json +0 -16
- homeassistant/components/zha/__init__.py +1 -16
- homeassistant/components/zha/config_flow.py +48 -163
- homeassistant/components/zha/manifest.json +1 -1
- homeassistant/components/zha/radio_manager.py +2 -3
- homeassistant/components/zha/strings.json +15 -68
- homeassistant/components/zha/translations/bg.json +3 -20
- homeassistant/components/zha/translations/ca.json +3 -0
- homeassistant/components/zha/translations/cs.json +16 -30
- homeassistant/components/zha/translations/da.json +3 -0
- homeassistant/components/zha/translations/de.json +15 -68
- homeassistant/components/zha/translations/el.json +3 -0
- homeassistant/components/zha/translations/en-GB.json +15 -68
- homeassistant/components/zha/translations/en.json +15 -68
- homeassistant/components/zha/translations/es.json +18 -119
- homeassistant/components/zha/translations/et.json +15 -68
- homeassistant/components/zha/translations/fi.json +3 -0
- homeassistant/components/zha/translations/fr.json +18 -0
- homeassistant/components/zha/translations/ga.json +3 -0
- homeassistant/components/zha/translations/gsw.json +3 -0
- homeassistant/components/zha/translations/hu.json +3 -0
- homeassistant/components/zha/translations/id.json +3 -0
- homeassistant/components/zha/translations/it.json +3 -0
- homeassistant/components/zha/translations/ja.json +3 -0
- homeassistant/components/zha/translations/ko.json +9 -0
- homeassistant/components/zha/translations/lt.json +15 -68
- homeassistant/components/zha/translations/nb.json +3 -0
- homeassistant/components/zha/translations/nl.json +3 -0
- homeassistant/components/zha/translations/pl.json +3 -0
- homeassistant/components/zha/translations/pt-BR.json +3 -0
- homeassistant/components/zha/translations/pt.json +18 -0
- homeassistant/components/zha/translations/ro.json +3 -0
- homeassistant/components/zha/translations/ru.json +18 -0
- homeassistant/components/zha/translations/sk.json +15 -68
- homeassistant/components/zha/translations/sl.json +9 -0
- homeassistant/components/zha/translations/sr-Latn.json +14 -0
- homeassistant/components/zha/translations/sv.json +4 -0
- homeassistant/components/zha/translations/tr.json +3 -0
- homeassistant/components/zha/translations/uk.json +3 -0
- homeassistant/components/zha/translations/zh-Hans.json +16 -30
- homeassistant/components/zha/translations/zh-Hant.json +15 -68
- homeassistant/components/zwave_js/translations/es.json +0 -3
- homeassistant/const.py +1 -1
- homeassistant/generated/config_flows.py +1 -1
- homeassistant/generated/integrations.json +7 -2
- homeassistant/package_constraints.txt +1 -1
- homeassistant/util/language.py +7 -17
- {homeassistant-2025.11.0.dist-info → homeassistant-2025.11.0b2.dist-info}/METADATA +1 -1
- {homeassistant-2025.11.0.dist-info → homeassistant-2025.11.0b2.dist-info}/RECORD +251 -240
- homeassistant/components/fing/translations/bg.json +0 -20
- homeassistant/components/fing/translations/es.json +0 -31
- homeassistant/components/inels/translations/bg.json +0 -1
- homeassistant/components/inels/translations/es.json +0 -30
- homeassistant/components/sunricher_dali/const.py +0 -5
- /homeassistant/components/{sunricher_dali → sunricher_dali_center}/quality_scale.yaml +0 -0
- {homeassistant-2025.11.0.dist-info → homeassistant-2025.11.0b2.dist-info}/WHEEL +0 -0
- {homeassistant-2025.11.0.dist-info → homeassistant-2025.11.0b2.dist-info}/entry_points.txt +0 -0
- {homeassistant-2025.11.0.dist-info → homeassistant-2025.11.0b2.dist-info}/licenses/LICENSE.md +0 -0
- {homeassistant-2025.11.0.dist-info → homeassistant-2025.11.0b2.dist-info}/licenses/homeassistant/backports/LICENSE.Python +0 -0
- {homeassistant-2025.11.0.dist-info → homeassistant-2025.11.0b2.dist-info}/top_level.txt +0 -0
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
5
|
-
from dataclasses import dataclass
|
|
6
5
|
from typing import Any
|
|
7
6
|
|
|
8
7
|
from homeassistant.components.climate import (
|
|
@@ -14,44 +13,18 @@ from homeassistant.components.climate import (
|
|
|
14
13
|
HVACAction,
|
|
15
14
|
HVACMode,
|
|
16
15
|
)
|
|
17
|
-
from homeassistant.const import ATTR_TEMPERATURE,
|
|
16
|
+
from homeassistant.const import ATTR_TEMPERATURE, UnitOfTemperature
|
|
18
17
|
from homeassistant.core import HomeAssistant, callback
|
|
19
|
-
from homeassistant.exceptions import HomeAssistantError
|
|
20
18
|
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback
|
|
21
|
-
from homeassistant.helpers.restore_state import ExtraStoredData, RestoreEntity
|
|
22
19
|
|
|
23
20
|
from .const import DOMAIN, MASTER_THERMOSTATS
|
|
24
21
|
from .coordinator import PlugwiseConfigEntry, PlugwiseDataUpdateCoordinator
|
|
25
22
|
from .entity import PlugwiseEntity
|
|
26
23
|
from .util import plugwise_command
|
|
27
24
|
|
|
28
|
-
ERROR_NO_SCHEDULE = "set_schedule_first"
|
|
29
25
|
PARALLEL_UPDATES = 0
|
|
30
26
|
|
|
31
27
|
|
|
32
|
-
@dataclass
|
|
33
|
-
class PlugwiseClimateExtraStoredData(ExtraStoredData):
|
|
34
|
-
"""Object to hold extra stored data."""
|
|
35
|
-
|
|
36
|
-
last_active_schedule: str | None
|
|
37
|
-
previous_action_mode: str | None
|
|
38
|
-
|
|
39
|
-
def as_dict(self) -> dict[str, Any]:
|
|
40
|
-
"""Return a dict representation of the text data."""
|
|
41
|
-
return {
|
|
42
|
-
"last_active_schedule": self.last_active_schedule,
|
|
43
|
-
"previous_action_mode": self.previous_action_mode,
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
@classmethod
|
|
47
|
-
def from_dict(cls, restored: dict[str, Any]) -> PlugwiseClimateExtraStoredData:
|
|
48
|
-
"""Initialize a stored data object from a dict."""
|
|
49
|
-
return cls(
|
|
50
|
-
last_active_schedule=restored.get("last_active_schedule"),
|
|
51
|
-
previous_action_mode=restored.get("previous_action_mode"),
|
|
52
|
-
)
|
|
53
|
-
|
|
54
|
-
|
|
55
28
|
async def async_setup_entry(
|
|
56
29
|
hass: HomeAssistant,
|
|
57
30
|
entry: PlugwiseConfigEntry,
|
|
@@ -83,26 +56,14 @@ async def async_setup_entry(
|
|
|
83
56
|
entry.async_on_unload(coordinator.async_add_listener(_add_entities))
|
|
84
57
|
|
|
85
58
|
|
|
86
|
-
class PlugwiseClimateEntity(PlugwiseEntity, ClimateEntity
|
|
59
|
+
class PlugwiseClimateEntity(PlugwiseEntity, ClimateEntity):
|
|
87
60
|
"""Representation of a Plugwise thermostat."""
|
|
88
61
|
|
|
89
62
|
_attr_name = None
|
|
90
63
|
_attr_temperature_unit = UnitOfTemperature.CELSIUS
|
|
91
64
|
_attr_translation_key = DOMAIN
|
|
92
65
|
|
|
93
|
-
|
|
94
|
-
_previous_action_mode: str | None = HVACAction.HEATING.value
|
|
95
|
-
|
|
96
|
-
async def async_added_to_hass(self) -> None:
|
|
97
|
-
"""Run when entity about to be added."""
|
|
98
|
-
await super().async_added_to_hass()
|
|
99
|
-
|
|
100
|
-
if extra_data := await self.async_get_last_extra_data():
|
|
101
|
-
plugwise_extra_data = PlugwiseClimateExtraStoredData.from_dict(
|
|
102
|
-
extra_data.as_dict()
|
|
103
|
-
)
|
|
104
|
-
self._last_active_schedule = plugwise_extra_data.last_active_schedule
|
|
105
|
-
self._previous_action_mode = plugwise_extra_data.previous_action_mode
|
|
66
|
+
_previous_mode: str = "heating"
|
|
106
67
|
|
|
107
68
|
def __init__(
|
|
108
69
|
self,
|
|
@@ -115,6 +76,7 @@ class PlugwiseClimateEntity(PlugwiseEntity, ClimateEntity, RestoreEntity):
|
|
|
115
76
|
|
|
116
77
|
gateway_id: str = coordinator.api.gateway_id
|
|
117
78
|
self._gateway_data = coordinator.data[gateway_id]
|
|
79
|
+
|
|
118
80
|
self._location = device_id
|
|
119
81
|
if (location := self.device.get("location")) is not None:
|
|
120
82
|
self._location = location
|
|
@@ -143,19 +105,25 @@ class PlugwiseClimateEntity(PlugwiseEntity, ClimateEntity, RestoreEntity):
|
|
|
143
105
|
self.device["thermostat"]["resolution"], 0.1
|
|
144
106
|
)
|
|
145
107
|
|
|
108
|
+
def _previous_action_mode(self, coordinator: PlugwiseDataUpdateCoordinator) -> None:
|
|
109
|
+
"""Return the previous action-mode when the regulation-mode is not heating or cooling.
|
|
110
|
+
|
|
111
|
+
Helper for set_hvac_mode().
|
|
112
|
+
"""
|
|
113
|
+
# When no cooling available, _previous_mode is always heating
|
|
114
|
+
if (
|
|
115
|
+
"regulation_modes" in self._gateway_data
|
|
116
|
+
and "cooling" in self._gateway_data["regulation_modes"]
|
|
117
|
+
):
|
|
118
|
+
mode = self._gateway_data["select_regulation_mode"]
|
|
119
|
+
if mode in ("cooling", "heating"):
|
|
120
|
+
self._previous_mode = mode
|
|
121
|
+
|
|
146
122
|
@property
|
|
147
123
|
def current_temperature(self) -> float:
|
|
148
124
|
"""Return the current temperature."""
|
|
149
125
|
return self.device["sensors"]["temperature"]
|
|
150
126
|
|
|
151
|
-
@property
|
|
152
|
-
def extra_restore_state_data(self) -> PlugwiseClimateExtraStoredData:
|
|
153
|
-
"""Return text specific state data to be restored."""
|
|
154
|
-
return PlugwiseClimateExtraStoredData(
|
|
155
|
-
last_active_schedule=self._last_active_schedule,
|
|
156
|
-
previous_action_mode=self._previous_action_mode,
|
|
157
|
-
)
|
|
158
|
-
|
|
159
127
|
@property
|
|
160
128
|
def target_temperature(self) -> float:
|
|
161
129
|
"""Return the temperature we try to reach.
|
|
@@ -202,10 +170,9 @@ class PlugwiseClimateEntity(PlugwiseEntity, ClimateEntity, RestoreEntity):
|
|
|
202
170
|
|
|
203
171
|
if self.coordinator.api.cooling_present:
|
|
204
172
|
if "regulation_modes" in self._gateway_data:
|
|
205
|
-
|
|
206
|
-
if selected == HVACAction.COOLING.value:
|
|
173
|
+
if self._gateway_data["select_regulation_mode"] == "cooling":
|
|
207
174
|
hvac_modes.append(HVACMode.COOL)
|
|
208
|
-
if
|
|
175
|
+
if self._gateway_data["select_regulation_mode"] == "heating":
|
|
209
176
|
hvac_modes.append(HVACMode.HEAT)
|
|
210
177
|
else:
|
|
211
178
|
hvac_modes.append(HVACMode.HEAT_COOL)
|
|
@@ -217,16 +184,8 @@ class PlugwiseClimateEntity(PlugwiseEntity, ClimateEntity, RestoreEntity):
|
|
|
217
184
|
@property
|
|
218
185
|
def hvac_action(self) -> HVACAction:
|
|
219
186
|
"""Return the current running hvac operation if supported."""
|
|
220
|
-
# Keep track of the previous
|
|
221
|
-
|
|
222
|
-
if (
|
|
223
|
-
"regulation_modes" in self._gateway_data
|
|
224
|
-
and HVACAction.COOLING.value in self._gateway_data["regulation_modes"]
|
|
225
|
-
):
|
|
226
|
-
mode = self._gateway_data["select_regulation_mode"]
|
|
227
|
-
if mode in (HVACAction.COOLING.value, HVACAction.HEATING.value):
|
|
228
|
-
self._previous_action_mode = mode
|
|
229
|
-
|
|
187
|
+
# Keep track of the previous action-mode
|
|
188
|
+
self._previous_action_mode(self.coordinator)
|
|
230
189
|
if (action := self.device.get("control_state")) is not None:
|
|
231
190
|
return HVACAction(action)
|
|
232
191
|
|
|
@@ -260,33 +219,14 @@ class PlugwiseClimateEntity(PlugwiseEntity, ClimateEntity, RestoreEntity):
|
|
|
260
219
|
return
|
|
261
220
|
|
|
262
221
|
if hvac_mode == HVACMode.OFF:
|
|
263
|
-
await self.coordinator.api.set_regulation_mode(hvac_mode
|
|
222
|
+
await self.coordinator.api.set_regulation_mode(hvac_mode)
|
|
264
223
|
else:
|
|
265
|
-
current = self.device.get("select_schedule")
|
|
266
|
-
desired = current
|
|
267
|
-
|
|
268
|
-
# Capture the last valid schedule
|
|
269
|
-
if desired and desired != "off":
|
|
270
|
-
self._last_active_schedule = desired
|
|
271
|
-
elif desired == "off":
|
|
272
|
-
desired = self._last_active_schedule
|
|
273
|
-
|
|
274
|
-
# Enabling HVACMode.AUTO requires a previously set schedule for saving and restoring
|
|
275
|
-
if hvac_mode == HVACMode.AUTO and not desired:
|
|
276
|
-
raise HomeAssistantError(
|
|
277
|
-
translation_domain=DOMAIN,
|
|
278
|
-
translation_key=ERROR_NO_SCHEDULE,
|
|
279
|
-
)
|
|
280
|
-
|
|
281
224
|
await self.coordinator.api.set_schedule_state(
|
|
282
225
|
self._location,
|
|
283
|
-
|
|
284
|
-
desired,
|
|
226
|
+
"on" if hvac_mode == HVACMode.AUTO else "off",
|
|
285
227
|
)
|
|
286
|
-
if self.hvac_mode == HVACMode.OFF
|
|
287
|
-
await self.coordinator.api.set_regulation_mode(
|
|
288
|
-
self._previous_action_mode
|
|
289
|
-
)
|
|
228
|
+
if self.hvac_mode == HVACMode.OFF:
|
|
229
|
+
await self.coordinator.api.set_regulation_mode(self._previous_mode)
|
|
290
230
|
|
|
291
231
|
@plugwise_command
|
|
292
232
|
async def async_set_preset_mode(self, preset_mode: str) -> None:
|
|
@@ -314,9 +314,6 @@
|
|
|
314
314
|
"invalid_xml_data": {
|
|
315
315
|
"message": "[%key:component::plugwise::config::error::response_error%]"
|
|
316
316
|
},
|
|
317
|
-
"set_schedule_first": {
|
|
318
|
-
"message": "Failed setting HVACMode, set a schedule first."
|
|
319
|
-
},
|
|
320
317
|
"unsupported_firmware": {
|
|
321
318
|
"message": "[%key:component::plugwise::config::error::unsupported%]"
|
|
322
319
|
}
|
|
@@ -314,9 +314,6 @@
|
|
|
314
314
|
"invalid_xml_data": {
|
|
315
315
|
"message": "Ung\u00fcltige XML-Daten oder Fehleranzeige empfangen"
|
|
316
316
|
},
|
|
317
|
-
"set_schedule_first": {
|
|
318
|
-
"message": "Fehler beim Einstellen des HLK-Modus, lege zuerst einen Zeitplan fest."
|
|
319
|
-
},
|
|
320
317
|
"unsupported_firmware": {
|
|
321
318
|
"message": "Ger\u00e4t mit nicht unterst\u00fctzter Firmware"
|
|
322
319
|
}
|
|
@@ -314,9 +314,6 @@
|
|
|
314
314
|
"invalid_xml_data": {
|
|
315
315
|
"message": "Invalid XML data, or error indication received"
|
|
316
316
|
},
|
|
317
|
-
"set_schedule_first": {
|
|
318
|
-
"message": "Failed setting HVACMode, set a schedule first."
|
|
319
|
-
},
|
|
320
317
|
"unsupported_firmware": {
|
|
321
318
|
"message": "Device with unsupported firmware"
|
|
322
319
|
}
|
|
@@ -314,9 +314,6 @@
|
|
|
314
314
|
"invalid_xml_data": {
|
|
315
315
|
"message": "Invalid XML data, or error indication received"
|
|
316
316
|
},
|
|
317
|
-
"set_schedule_first": {
|
|
318
|
-
"message": "Failed setting HVACMode, set a schedule first."
|
|
319
|
-
},
|
|
320
317
|
"unsupported_firmware": {
|
|
321
318
|
"message": "Device with unsupported firmware"
|
|
322
319
|
}
|
|
@@ -314,9 +314,6 @@
|
|
|
314
314
|
"invalid_xml_data": {
|
|
315
315
|
"message": "Datos XML no v\u00e1lidos o indicaci\u00f3n de error recibida"
|
|
316
316
|
},
|
|
317
|
-
"set_schedule_first": {
|
|
318
|
-
"message": "Error al configurar el modo de climatizaci\u00f3n (HVACMode); primero debes establecer una programaci\u00f3n."
|
|
319
|
-
},
|
|
320
317
|
"unsupported_firmware": {
|
|
321
318
|
"message": "Dispositivo con firmware no compatible"
|
|
322
319
|
}
|
|
@@ -314,9 +314,6 @@
|
|
|
314
314
|
"invalid_xml_data": {
|
|
315
315
|
"message": "Vigased XML-andmed v\u00f5i saadud veam\u00e4rguanne"
|
|
316
316
|
},
|
|
317
|
-
"set_schedule_first": {
|
|
318
|
-
"message": "HVAC-re\u017eiimi seadistamine eba\u00f5nnestus, m\u00e4\u00e4ra esmalt ajakava."
|
|
319
|
-
},
|
|
320
317
|
"unsupported_firmware": {
|
|
321
318
|
"message": "Toetamata p\u00fcsivaraga seade"
|
|
322
319
|
}
|
|
@@ -314,9 +314,6 @@
|
|
|
314
314
|
"invalid_xml_data": {
|
|
315
315
|
"message": "Gauti neteisingi XML duomenys arba gautas klaidos prane\u0161imas"
|
|
316
316
|
},
|
|
317
|
-
"set_schedule_first": {
|
|
318
|
-
"message": "Nepavyko nustatyti HVACMode, pirmiausia nustatykite tvarkara\u0161t\u012f."
|
|
319
|
-
},
|
|
320
317
|
"unsupported_firmware": {
|
|
321
318
|
"message": "Prietaisas su nepalaikoma programine-technine \u012franga"
|
|
322
319
|
}
|
|
@@ -314,9 +314,6 @@
|
|
|
314
314
|
"invalid_xml_data": {
|
|
315
315
|
"message": "Neplatn\u00e9 \u00fadaje XML alebo prijat\u00e9 chybov\u00e9 hl\u00e1senie"
|
|
316
316
|
},
|
|
317
|
-
"set_schedule_first": {
|
|
318
|
-
"message": "Nastavenie re\u017eimu HVAC zlyhalo, najprv nastavte pl\u00e1n."
|
|
319
|
-
},
|
|
320
317
|
"unsupported_firmware": {
|
|
321
318
|
"message": "Zariadenie s nepodporovan\u00fdm firmv\u00e9rom"
|
|
322
319
|
}
|
|
@@ -314,9 +314,6 @@
|
|
|
314
314
|
"invalid_xml_data": {
|
|
315
315
|
"message": "XML \u8cc7\u6599\u7121\u6548\u3001\u6216\u63a5\u6536\u5230\u932f\u8aa4\u6307\u793a"
|
|
316
316
|
},
|
|
317
|
-
"set_schedule_first": {
|
|
318
|
-
"message": "\u8a2d\u5b9a HVACMode \u5931\u6557\u3001\u8acb\u5148\u8a2d\u5b9a\u6392\u7a0b\u3002"
|
|
319
|
-
},
|
|
320
317
|
"unsupported_firmware": {
|
|
321
318
|
"message": "\u88dd\u7f6e\u4f7f\u7528\u7684\u97cc\u9ad4\u4e0d\u652f\u63f4"
|
|
322
319
|
}
|
|
@@ -2,8 +2,7 @@
|
|
|
2
2
|
"config": {
|
|
3
3
|
"abort": {
|
|
4
4
|
"already_configured": "\u0423\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u043e\u0442\u043e \u0432\u0435\u0447\u0435 \u0435 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0438\u0440\u0430\u043d\u043e",
|
|
5
|
-
"reauth_successful": "\u041f\u043e\u0432\u0442\u043e\u0440\u043d\u0430\u0442\u0430 \u0430\u0432\u0442\u0435\u043d\u0442\u0438\u043a\u0430\u0446\u0438\u044f \u0431\u0435\u0448\u0435 \u0443\u0441\u043f\u0435\u0448\u043d\u0430"
|
|
6
|
-
"reconfigure_successful": "\u041f\u0440\u0435\u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0438\u0440\u0430\u043d\u0435\u0442\u043e \u0431\u0435\u0448\u0435 \u0443\u0441\u043f\u0435\u0448\u043d\u043e"
|
|
5
|
+
"reauth_successful": "\u041f\u043e\u0432\u0442\u043e\u0440\u043d\u0430\u0442\u0430 \u0430\u0432\u0442\u0435\u043d\u0442\u0438\u043a\u0430\u0446\u0438\u044f \u0431\u0435\u0448\u0435 \u0443\u0441\u043f\u0435\u0448\u043d\u0430"
|
|
7
6
|
},
|
|
8
7
|
"error": {
|
|
9
8
|
"cannot_connect": "\u041d\u0435\u0443\u0441\u043f\u0435\u0448\u043d\u043e \u0441\u0432\u044a\u0440\u0437\u0432\u0430\u043d\u0435",
|
|
@@ -11,12 +10,6 @@
|
|
|
11
10
|
"unknown": "\u041d\u0435\u043e\u0447\u0430\u043a\u0432\u0430\u043d\u0430 \u0433\u0440\u0435\u0448\u043a\u0430"
|
|
12
11
|
},
|
|
13
12
|
"step": {
|
|
14
|
-
"reconfigure": {
|
|
15
|
-
"data": {
|
|
16
|
-
"url": "URL",
|
|
17
|
-
"verify_ssl": "\u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u043d\u0430 SSL \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u0430"
|
|
18
|
-
}
|
|
19
|
-
},
|
|
20
13
|
"user": {
|
|
21
14
|
"data": {
|
|
22
15
|
"url": "URL",
|
|
@@ -14,9 +14,7 @@
|
|
|
14
14
|
"api_token": "API pristupni token za autentifikaciju sa Portainer\u2011om",
|
|
15
15
|
"url": "URL, uklju\u010duju\u0107i port, tvoje Portainer instance",
|
|
16
16
|
"verify_ssl": "Da li da se verifikuju SSL sertifikati. Onemogu\u0107i samo ako ima\u0161 samopotpisani sertifikat."
|
|
17
|
-
}
|
|
18
|
-
"description": "Upotrebite slede\u0107i obrazac da ponovo konfiguri\u0161ete svoju Portainer instancu.",
|
|
19
|
-
"title": "Ponovo konfiguri\u0161i Portainer integraciju"
|
|
17
|
+
}
|
|
20
18
|
},
|
|
21
19
|
"user": {
|
|
22
20
|
"data": {
|
|
@@ -3,9 +3,7 @@
|
|
|
3
3
|
"abort": {
|
|
4
4
|
"already_configured": "El dispositivo ya est\u00e1 configurado",
|
|
5
5
|
"credential_error": "Error al obtener las credenciales.",
|
|
6
|
-
"no_devices_found": "No se encontraron dispositivos en la red"
|
|
7
|
-
"port_987_bind_error": "No se pudo enlazar con el puerto 987. Consulta la [documentaci\u00f3n]({ps4_docs_url}) para obtener informaci\u00f3n adicional.",
|
|
8
|
-
"port_997_bind_error": "No se pudo enlazar con el puerto 997. Consulta la [documentaci\u00f3n]({ps4_docs_url}) para obtener informaci\u00f3n adicional."
|
|
6
|
+
"no_devices_found": "No se encontraron dispositivos en la red"
|
|
9
7
|
},
|
|
10
8
|
"error": {
|
|
11
9
|
"cannot_connect": "No se pudo conectar",
|
|
@@ -15,12 +13,6 @@
|
|
|
15
13
|
},
|
|
16
14
|
"step": {
|
|
17
15
|
"creds": {
|
|
18
|
-
"data": {
|
|
19
|
-
"token": "Token de PSN"
|
|
20
|
-
},
|
|
21
|
-
"data_description": {
|
|
22
|
-
"token": "Para obtener tu token de PSN, por favor, sigue estas [instrucciones]({ps4_docs_url})."
|
|
23
|
-
},
|
|
24
16
|
"description": "Credenciales necesarias. Pulsa **Enviar** y luego en la aplicaci\u00f3n PS4 Second Screen, actualiza los dispositivos y selecciona el dispositivo **Home-Assistant** para continuar."
|
|
25
17
|
},
|
|
26
18
|
"link": {
|
|
@@ -654,8 +654,8 @@
|
|
|
654
654
|
"animal_type": {
|
|
655
655
|
"name": "Typ zwierz\u0119cia",
|
|
656
656
|
"state": {
|
|
657
|
-
"cat": "
|
|
658
|
-
"dog": "
|
|
657
|
+
"cat": "Kot",
|
|
658
|
+
"dog": "Pies"
|
|
659
659
|
}
|
|
660
660
|
},
|
|
661
661
|
"battery_state": {
|
|
@@ -686,8 +686,8 @@
|
|
|
686
686
|
"person_type": {
|
|
687
687
|
"name": "Typ osoby",
|
|
688
688
|
"state": {
|
|
689
|
-
"man": "
|
|
690
|
-
"woman": "
|
|
689
|
+
"man": "M\u0119\u017cczyzna",
|
|
690
|
+
"woman": "Kobieta"
|
|
691
691
|
}
|
|
692
692
|
},
|
|
693
693
|
"ptz_pan_position": {
|
|
@@ -702,10 +702,9 @@
|
|
|
702
702
|
"vehicle_type": {
|
|
703
703
|
"name": "Typ pojazdu",
|
|
704
704
|
"state": {
|
|
705
|
-
"
|
|
706
|
-
"
|
|
707
|
-
"
|
|
708
|
-
"sedan": "sedan",
|
|
705
|
+
"motorcycle": "Motocykl",
|
|
706
|
+
"pickup_truck": "Pickup",
|
|
707
|
+
"sedan": "Sedan",
|
|
709
708
|
"suv": "SUV"
|
|
710
709
|
}
|
|
711
710
|
},
|
|
@@ -64,8 +64,7 @@
|
|
|
64
64
|
"button1": "\u041f\u044a\u0440\u0432\u0438 \u0431\u0443\u0442\u043e\u043d",
|
|
65
65
|
"button2": "\u0412\u0442\u043e\u0440\u0438 \u0431\u0443\u0442\u043e\u043d",
|
|
66
66
|
"button3": "\u0422\u0440\u0435\u0442\u0438 \u0431\u0443\u0442\u043e\u043d",
|
|
67
|
-
"button4": "\u0427\u0435\u0442\u0432\u044a\u0440\u0442\u0438 \u0431\u0443\u0442\u043e\u043d"
|
|
68
|
-
"button5": "\u041f\u0435\u0442\u0438 \u0431\u0443\u0442\u043e\u043d"
|
|
67
|
+
"button4": "\u0427\u0435\u0442\u0432\u044a\u0440\u0442\u0438 \u0431\u0443\u0442\u043e\u043d"
|
|
69
68
|
},
|
|
70
69
|
"trigger_type": {
|
|
71
70
|
"double": "{subtype} \u0434\u0432\u0443\u043a\u0440\u0430\u0442\u043d\u043e \u0449\u0440\u0430\u043a\u0432\u0430\u043d\u0435",
|
|
@@ -110,15 +110,11 @@
|
|
|
110
110
|
"state": {
|
|
111
111
|
"btn_down": "Bot\u00f3n abajo",
|
|
112
112
|
"btn_up": "Bot\u00f3n arriba",
|
|
113
|
-
"double": "Pulsaci\u00f3n doble",
|
|
114
113
|
"double_push": "Pulsaci\u00f3n doble",
|
|
115
|
-
"long": "Pulsaci\u00f3n larga",
|
|
116
114
|
"long_push": "Pulsaci\u00f3n larga",
|
|
117
115
|
"long_single": "Pulsaci\u00f3n larga y a continuaci\u00f3n pulsaci\u00f3n corta",
|
|
118
|
-
"single": "Pulsaci\u00f3n simple",
|
|
119
116
|
"single_long": "Pulsaci\u00f3n corta y a continuaci\u00f3n pulsaci\u00f3n larga",
|
|
120
117
|
"single_push": "Pulsaci\u00f3n simple",
|
|
121
|
-
"triple": "Pulsaci\u00f3n triple",
|
|
122
118
|
"triple_push": "Pulsaci\u00f3n triple"
|
|
123
119
|
}
|
|
124
120
|
}
|
|
@@ -253,8 +249,7 @@
|
|
|
253
249
|
},
|
|
254
250
|
"step": {
|
|
255
251
|
"confirm": {
|
|
256
|
-
"description": "Tu dispositivo Shelly {device_name} con direcci\u00f3n IP {ip_address} ejecuta el firmware {firmware} y funciona como esc\u00e1ner BLE en modo activo. Esta versi\u00f3n de firmware no es compatible con el esc\u00e1ner BLE en modo activo. \n \nSelecciona el bot\u00f3n **Enviar** para iniciar la actualizaci\u00f3n OTA a la \u00faltima versi\u00f3n estable del firmware."
|
|
257
|
-
"title": "{device_name} est\u00e1 ejecutando un firmware no compatible"
|
|
252
|
+
"description": "Tu dispositivo Shelly {device_name} con direcci\u00f3n IP {ip_address} ejecuta el firmware {firmware} y funciona como esc\u00e1ner BLE en modo activo. Esta versi\u00f3n de firmware no es compatible con el esc\u00e1ner BLE en modo activo. \n \nSelecciona el bot\u00f3n **Enviar** para iniciar la actualizaci\u00f3n OTA a la \u00faltima versi\u00f3n estable del firmware."
|
|
258
253
|
}
|
|
259
254
|
}
|
|
260
255
|
},
|
|
@@ -268,8 +263,7 @@
|
|
|
268
263
|
},
|
|
269
264
|
"step": {
|
|
270
265
|
"confirm": {
|
|
271
|
-
"description": "Tu dispositivo Shelly {device_name} con direcci\u00f3n IP {ip_address} ejecuta el firmware {firmware}. Esta versi\u00f3n de firmware no ser\u00e1 compatible con la integraci\u00f3n de Shelly a partir de Home Assistant {ha_version}. \n \nSelecciona el bot\u00f3n **Enviar** para iniciar la actualizaci\u00f3n OTA a la \u00faltima versi\u00f3n estable del firmware."
|
|
272
|
-
"title": "{device_name} est\u00e1 ejecutando un firmware desactualizado"
|
|
266
|
+
"description": "Tu dispositivo Shelly {device_name} con direcci\u00f3n IP {ip_address} ejecuta el firmware {firmware}. Esta versi\u00f3n de firmware no ser\u00e1 compatible con la integraci\u00f3n de Shelly a partir de Home Assistant {ha_version}. \n \nSelecciona el bot\u00f3n **Enviar** para iniciar la actualizaci\u00f3n OTA a la \u00faltima versi\u00f3n estable del firmware."
|
|
273
267
|
}
|
|
274
268
|
}
|
|
275
269
|
},
|
|
@@ -286,8 +280,7 @@
|
|
|
286
280
|
},
|
|
287
281
|
"step": {
|
|
288
282
|
"confirm": {
|
|
289
|
-
"description": "Tu dispositivo Shelly {device_name} con direcci\u00f3n IP {ip_address} es un dispositivo que no est\u00e1 inactivo y el WebSocket de salida debe estar deshabilitado en su configuraci\u00f3n. \n \nSelecciona el bot\u00f3n **Enviar** para deshabilitar el WebSocket de salida."
|
|
290
|
-
"title": "El WebSocket de salida est\u00e1 habilitado para {device_name}"
|
|
283
|
+
"description": "Tu dispositivo Shelly {device_name} con direcci\u00f3n IP {ip_address} es un dispositivo que no est\u00e1 inactivo y el WebSocket de salida debe estar deshabilitado en su configuraci\u00f3n. \n \nSelecciona el bot\u00f3n **Enviar** para deshabilitar el WebSocket de salida."
|
|
291
284
|
}
|
|
292
285
|
}
|
|
293
286
|
},
|
|
@@ -70,7 +70,7 @@
|
|
|
70
70
|
"invert_position": "Invertir posici\u00f3n"
|
|
71
71
|
},
|
|
72
72
|
"data_description": {
|
|
73
|
-
"invert_position": "Invierte la posici\u00f3n de la
|
|
73
|
+
"invert_position": "Invierte la posici\u00f3n de la cubierta Slide."
|
|
74
74
|
},
|
|
75
75
|
"description": "Volver a configurar el dispositivo Slide",
|
|
76
76
|
"title": "Configurar Slide"
|
|
@@ -30,16 +30,16 @@
|
|
|
30
30
|
"step": {
|
|
31
31
|
"init": {
|
|
32
32
|
"data": {
|
|
33
|
-
"target_id": "Configurar opciones para una
|
|
33
|
+
"target_id": "Configurar opciones para una cubierta."
|
|
34
34
|
},
|
|
35
35
|
"title": "Configurar las opciones de MyLink"
|
|
36
36
|
},
|
|
37
37
|
"target_config": {
|
|
38
38
|
"data": {
|
|
39
|
-
"reverse": "La
|
|
39
|
+
"reverse": "La cubierta est\u00e1 invertida"
|
|
40
40
|
},
|
|
41
41
|
"description": "Configurar opciones para `{target_name}`",
|
|
42
|
-
"title": "Configurar la
|
|
42
|
+
"title": "Configurar la cubierta de MyLink"
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
45
|
}
|
|
@@ -4,13 +4,11 @@ import logging
|
|
|
4
4
|
|
|
5
5
|
from libsoundtouch import soundtouch_device
|
|
6
6
|
from libsoundtouch.device import SoundTouchDevice
|
|
7
|
-
import requests
|
|
8
7
|
import voluptuous as vol
|
|
9
8
|
|
|
10
9
|
from homeassistant.config_entries import ConfigEntry
|
|
11
10
|
from homeassistant.const import CONF_HOST, Platform
|
|
12
11
|
from homeassistant.core import HomeAssistant, ServiceCall
|
|
13
|
-
from homeassistant.exceptions import ConfigEntryNotReady
|
|
14
12
|
from homeassistant.helpers import config_validation as cv
|
|
15
13
|
from homeassistant.helpers.typing import ConfigType
|
|
16
14
|
|
|
@@ -132,14 +130,7 @@ async def async_setup(hass: HomeAssistant, config: ConfigType) -> bool:
|
|
|
132
130
|
|
|
133
131
|
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
|
134
132
|
"""Set up Bose SoundTouch from a config entry."""
|
|
135
|
-
|
|
136
|
-
device = await hass.async_add_executor_job(
|
|
137
|
-
soundtouch_device, entry.data[CONF_HOST]
|
|
138
|
-
)
|
|
139
|
-
except requests.exceptions.ConnectionError as err:
|
|
140
|
-
raise ConfigEntryNotReady(
|
|
141
|
-
f"Unable to connect to SoundTouch device at {entry.data[CONF_HOST]}"
|
|
142
|
-
) from err
|
|
133
|
+
device = await hass.async_add_executor_job(soundtouch_device, entry.data[CONF_HOST])
|
|
143
134
|
|
|
144
135
|
hass.data.setdefault(DOMAIN, {})[entry.entry_id] = SoundTouchData(device)
|
|
145
136
|
|