mirror of
https://github.com/home-assistant/core.git
synced 2026-10-07 06:50:41 -04:00
Fix Overkiz heat recovery ventilation crash without ventilation mode state (#183382)
This commit is contained in:
@@ -95,8 +95,11 @@ class AtlanticHeatRecoveryVentilation(OverkizEntity, ClimateEntity):
|
||||
return PRESET_MANUAL
|
||||
|
||||
ventilation_mode = cast(
|
||||
dict, self.device.states.get_value(OverkizState.IO_VENTILATION_MODE)
|
||||
dict | None, self.device.states.get_value(OverkizState.IO_VENTILATION_MODE)
|
||||
)
|
||||
if ventilation_mode is None:
|
||||
return None
|
||||
|
||||
prog = ventilation_mode.get(OverkizCommandParam.PROG)
|
||||
|
||||
if prog == OverkizCommandParam.ON:
|
||||
@@ -140,9 +143,13 @@ class AtlanticHeatRecoveryVentilation(OverkizEntity, ClimateEntity):
|
||||
def fan_mode(self) -> str | None:
|
||||
"""Return the fan setting."""
|
||||
ventilation_mode = cast(
|
||||
dict, self.device.states.get_value(OverkizState.IO_VENTILATION_MODE)
|
||||
dict | None, self.device.states.get_value(OverkizState.IO_VENTILATION_MODE)
|
||||
)
|
||||
cooling = (
|
||||
ventilation_mode.get(OverkizCommandParam.COOLING)
|
||||
if ventilation_mode is not None
|
||||
else None
|
||||
)
|
||||
cooling = ventilation_mode.get(OverkizCommandParam.COOLING)
|
||||
|
||||
if cooling == OverkizCommandParam.ON:
|
||||
return FAN_BYPASS
|
||||
@@ -176,8 +183,11 @@ class AtlanticHeatRecoveryVentilation(OverkizEntity, ClimateEntity):
|
||||
) -> None:
|
||||
"""Execute ventilation mode command with all parameters."""
|
||||
ventilation_mode = cast(
|
||||
dict, self.device.states.get_value(OverkizState.IO_VENTILATION_MODE)
|
||||
dict | None, self.device.states.get_value(OverkizState.IO_VENTILATION_MODE)
|
||||
)
|
||||
# The Local API can omit this state, and the command needs all its parameters
|
||||
if ventilation_mode is None:
|
||||
return
|
||||
|
||||
if cooling:
|
||||
ventilation_mode[OverkizCommandParam.COOLING] = cooling
|
||||
|
||||
@@ -6554,6 +6554,787 @@
|
||||
"widgetName": "DynamicExteriorVenetianBlind"
|
||||
},
|
||||
"deviceURL": "io://1234-5678-6508/11292138"
|
||||
},
|
||||
{
|
||||
"type": 1,
|
||||
"synced": true,
|
||||
"enabled": true,
|
||||
"deviceURL": "io://1234-5678-6508/2840629#1",
|
||||
"subsystemId": 1,
|
||||
"available": true,
|
||||
"definition": {
|
||||
"type": "ACTUATOR",
|
||||
"states": [
|
||||
{
|
||||
"name": "io:SensorsErrorState"
|
||||
},
|
||||
{
|
||||
"name": "io:VentilationConfigurationModeState"
|
||||
},
|
||||
{
|
||||
"name": "io:AirDemandModeState"
|
||||
},
|
||||
{
|
||||
"name": "core:StatusState"
|
||||
},
|
||||
{
|
||||
"name": "io:VentilationModeState"
|
||||
},
|
||||
{
|
||||
"name": "io:EnergySavingState"
|
||||
},
|
||||
{
|
||||
"name": "io:CO2HistoryState"
|
||||
},
|
||||
{
|
||||
"name": "core:CommandLockLevelsState"
|
||||
},
|
||||
{
|
||||
"name": "core:TimeProgramState"
|
||||
},
|
||||
{
|
||||
"name": "core:OperatingStateState"
|
||||
},
|
||||
{
|
||||
"name": "io:InletEngineState"
|
||||
},
|
||||
{
|
||||
"name": "io:OutletEngineState"
|
||||
},
|
||||
{
|
||||
"name": "io:ProgCommandState"
|
||||
},
|
||||
{
|
||||
"name": "io:RemainingTimeBeforeFilterChangeState"
|
||||
},
|
||||
{
|
||||
"name": "core:DiscreteRSSILevelState"
|
||||
},
|
||||
{
|
||||
"name": "core:RSSILevelState"
|
||||
},
|
||||
{
|
||||
"name": "core:PriorityLockTimerState"
|
||||
},
|
||||
{
|
||||
"name": "io:PriorityLockLevelState"
|
||||
},
|
||||
{
|
||||
"name": "io:PriorityLockOriginatorState"
|
||||
},
|
||||
{
|
||||
"name": "core:AirDemandState"
|
||||
},
|
||||
{
|
||||
"name": "core:NameState"
|
||||
}
|
||||
],
|
||||
"commands": [
|
||||
{
|
||||
"commandName": "refreshTimeProgram",
|
||||
"nparams": 0
|
||||
},
|
||||
{
|
||||
"commandName": "setTimeProgram",
|
||||
"nparams": 1,
|
||||
"paramsSig": "p1"
|
||||
},
|
||||
{
|
||||
"commandName": "getName",
|
||||
"nparams": 0
|
||||
},
|
||||
{
|
||||
"commandName": "pairOneWayController",
|
||||
"nparams": 1,
|
||||
"paramsSig": "p1,*p2"
|
||||
},
|
||||
{
|
||||
"commandName": "setAirDemandMode",
|
||||
"nparams": 1,
|
||||
"paramsSig": "p1"
|
||||
},
|
||||
{
|
||||
"commandName": "resetVentilation",
|
||||
"nparams": 0,
|
||||
"paramsSig": "*p1,*p2,*p3"
|
||||
},
|
||||
{
|
||||
"commandName": "advancedRefresh",
|
||||
"nparams": 1,
|
||||
"paramsSig": "p1,*p2"
|
||||
},
|
||||
{
|
||||
"commandName": "refreshVentilationState",
|
||||
"nparams": 0
|
||||
},
|
||||
{
|
||||
"commandName": "delayedStopIdentify",
|
||||
"nparams": 1,
|
||||
"paramsSig": "p1"
|
||||
},
|
||||
{
|
||||
"commandName": "refreshVentilationConfigurationMode",
|
||||
"nparams": 0
|
||||
},
|
||||
{
|
||||
"commandName": "unpairOneWayController",
|
||||
"nparams": 1,
|
||||
"paramsSig": "p1,*p2"
|
||||
},
|
||||
{
|
||||
"commandName": "refreshSensorsState",
|
||||
"nparams": 0
|
||||
},
|
||||
{
|
||||
"commandName": "refreshEnergySaving",
|
||||
"nparams": 0
|
||||
},
|
||||
{
|
||||
"commandName": "refreshCO2History",
|
||||
"nparams": 0
|
||||
},
|
||||
{
|
||||
"commandName": "wink",
|
||||
"nparams": 1,
|
||||
"paramsSig": "p1"
|
||||
},
|
||||
{
|
||||
"commandName": "addLockLevel",
|
||||
"nparams": 1,
|
||||
"paramsSig": "p1,*p2"
|
||||
},
|
||||
{
|
||||
"commandName": "stopIdentify",
|
||||
"nparams": 0
|
||||
},
|
||||
{
|
||||
"commandName": "startIdentify",
|
||||
"nparams": 0
|
||||
},
|
||||
{
|
||||
"commandName": "identify",
|
||||
"nparams": 0
|
||||
},
|
||||
{
|
||||
"commandName": "setName",
|
||||
"nparams": 1,
|
||||
"paramsSig": "p1"
|
||||
},
|
||||
{
|
||||
"commandName": "setVentilationMode",
|
||||
"nparams": 1,
|
||||
"paramsSig": "p1"
|
||||
},
|
||||
{
|
||||
"commandName": "resetLockLevels",
|
||||
"nparams": 0
|
||||
},
|
||||
{
|
||||
"commandName": "removeLockLevel",
|
||||
"nparams": 1,
|
||||
"paramsSig": "p1"
|
||||
},
|
||||
{
|
||||
"commandName": "unpairAllOneWayControllers",
|
||||
"nparams": 0
|
||||
},
|
||||
{
|
||||
"commandName": "setVentilationConfigurationMode",
|
||||
"nparams": 1,
|
||||
"paramsSig": "p1"
|
||||
}
|
||||
],
|
||||
"uiClass": "VentilationSystem",
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer"
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision"
|
||||
}
|
||||
],
|
||||
"widgetName": "AtlanticHeatRecoveryVentilation"
|
||||
},
|
||||
"controllableName": "io:AtlanticHeatRecoveryVentilationIOComponent",
|
||||
"label": "Ventilation",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:StatusState",
|
||||
"value": "available",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:CommandLockLevelsState",
|
||||
"value": [],
|
||||
"type": 11
|
||||
},
|
||||
{
|
||||
"name": "core:DiscreteRSSILevelState",
|
||||
"value": "good",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:RSSILevelState",
|
||||
"value": 100,
|
||||
"type": 1
|
||||
},
|
||||
{
|
||||
"name": "io:VentilationConfigurationModeState",
|
||||
"value": "comfort",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:AirDemandState",
|
||||
"value": 100,
|
||||
"type": 1
|
||||
},
|
||||
{
|
||||
"name": "io:AirDemandModeState",
|
||||
"value": "auto",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:NameState",
|
||||
"value": "Ventilation",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "io:SensorsErrorState",
|
||||
"value": {
|
||||
"outlet": {
|
||||
"exhaustAir": false,
|
||||
"newAir": false
|
||||
},
|
||||
"co2": false,
|
||||
"outside": false,
|
||||
"inlet": {
|
||||
"exhaustAir": false,
|
||||
"newAir": false
|
||||
}
|
||||
},
|
||||
"type": 11
|
||||
},
|
||||
{
|
||||
"name": "core:OperatingStateState",
|
||||
"value": 8,
|
||||
"type": 1
|
||||
},
|
||||
{
|
||||
"name": "io:InletEngineState",
|
||||
"value": 114,
|
||||
"type": 1
|
||||
},
|
||||
{
|
||||
"name": "io:OutletEngineState",
|
||||
"value": 111,
|
||||
"type": 1
|
||||
},
|
||||
{
|
||||
"name": "io:ProgCommandState",
|
||||
"value": 0,
|
||||
"type": 1
|
||||
},
|
||||
{
|
||||
"name": "io:RemainingTimeBeforeFilterChangeState",
|
||||
"value": 3262,
|
||||
"type": 1
|
||||
},
|
||||
{
|
||||
"name": "core:TimeProgramState",
|
||||
"value": {
|
||||
"daymode": {
|
||||
"tuesday": "day-presence",
|
||||
"monday": "day-presence",
|
||||
"sunday": "day-presence",
|
||||
"wednesday": "day-presence",
|
||||
"thursday": "day-presence",
|
||||
"friday": "day-presence",
|
||||
"saturday": "day-presence"
|
||||
},
|
||||
"programs": [
|
||||
{
|
||||
"slots": {
|
||||
"count": 2,
|
||||
"definitions": [
|
||||
{
|
||||
"mode": "away",
|
||||
"start": "09:00"
|
||||
},
|
||||
{
|
||||
"mode": "presence",
|
||||
"start": "00:00"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"slots": {
|
||||
"count": 0,
|
||||
"definitions": []
|
||||
}
|
||||
}
|
||||
],
|
||||
"lastRequest": "gui"
|
||||
},
|
||||
"type": 11
|
||||
},
|
||||
{
|
||||
"name": "io:CO2HistoryState",
|
||||
"value": [
|
||||
67, 70, 68, 68, 68, 69, 69, 70, 71, 72, 72, 72, 73, 73, 73, 73, 74,
|
||||
81, 80, 68, 72, 73, 70, 69, 68, 72, 68, 66, 68, 66, 64, 62, 64, 63,
|
||||
62, 62, 60, 58, 56, 54, 53, 52, 52, 56, 59, 63, 67, 69, 72, 73, 74,
|
||||
74, 75, 74, 74, 72, 72, 72, 72, 73, 73, 73, 74, 75, 76, 85, 72, 73,
|
||||
73, 70, 66, 64, 61, 59, 59, 57, 57, 53, 51, 50, 49, 48, 48, 47, 46,
|
||||
46, 48, 54, 58, 59, 58, 58, 60, 62, 63, 65, 65, 65, 64, 63, 63, 63,
|
||||
63, 63, 64, 64, 64, 65, 65, 66, 66, 67, 67, 70, 77, 77, 72, 67, 65,
|
||||
63, 52, 49, 47, 49, 52, 53, 53, 55, 59, 63, 60, 61, 54, 49, 49, 52,
|
||||
53, 59, 59, 60, 60, 60, 60, 60, 22
|
||||
],
|
||||
"type": 10
|
||||
},
|
||||
{
|
||||
"name": "io:EnergySavingState",
|
||||
"value": 314,
|
||||
"type": 1
|
||||
}
|
||||
],
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer",
|
||||
"value": "Atlantic Group",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision",
|
||||
"value": "682008A",
|
||||
"type": 3
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": 2,
|
||||
"synced": true,
|
||||
"enabled": true,
|
||||
"deviceURL": "io://1234-5678-6508/2840629#2",
|
||||
"subsystemId": 2,
|
||||
"available": true,
|
||||
"definition": {
|
||||
"type": "SENSOR",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:CO2ConcentrationState"
|
||||
},
|
||||
{
|
||||
"name": "core:StatusState"
|
||||
}
|
||||
],
|
||||
"commands": [],
|
||||
"uiClass": "AirSensor",
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer"
|
||||
},
|
||||
{
|
||||
"name": "core:PowerSourceType"
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision"
|
||||
}
|
||||
],
|
||||
"widgetName": "CO2Sensor"
|
||||
},
|
||||
"controllableName": "io:CO2IOSystemDeviceSensor",
|
||||
"label": "Ventilation (Ventilation#2)",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:StatusState",
|
||||
"value": "available",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:CO2ConcentrationState",
|
||||
"value": 605,
|
||||
"type": 1
|
||||
}
|
||||
],
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer",
|
||||
"value": "Atlantic Group",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:PowerSourceType",
|
||||
"value": "mainSupply",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision",
|
||||
"value": "682008A",
|
||||
"type": 3
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": 2,
|
||||
"synced": true,
|
||||
"enabled": true,
|
||||
"deviceURL": "io://1234-5678-6508/2840629#3",
|
||||
"subsystemId": 3,
|
||||
"available": true,
|
||||
"definition": {
|
||||
"type": "SENSOR",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:TemperatureState"
|
||||
},
|
||||
{
|
||||
"name": "core:StatusState"
|
||||
}
|
||||
],
|
||||
"commands": [],
|
||||
"uiClass": "TemperatureSensor",
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer"
|
||||
},
|
||||
{
|
||||
"name": "core:PowerSourceType"
|
||||
},
|
||||
{
|
||||
"name": "core:MeasuredValueType"
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision"
|
||||
}
|
||||
],
|
||||
"widgetName": "TemperatureSensor"
|
||||
},
|
||||
"controllableName": "io:TemperatureInCelciusIOSystemDeviceSensor",
|
||||
"label": "Ventilation (Ventilation#3)",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:StatusState",
|
||||
"value": "available",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:TemperatureState",
|
||||
"value": -40,
|
||||
"type": 1
|
||||
}
|
||||
],
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer",
|
||||
"value": "Atlantic Group",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:PowerSourceType",
|
||||
"value": "mainSupply",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:MeasuredValueType",
|
||||
"value": "core:TemperatureInCelcius",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision",
|
||||
"value": "682008A",
|
||||
"type": 3
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": 2,
|
||||
"synced": true,
|
||||
"enabled": true,
|
||||
"deviceURL": "io://1234-5678-6508/2840629#4",
|
||||
"subsystemId": 4,
|
||||
"available": true,
|
||||
"definition": {
|
||||
"type": "SENSOR",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:TemperatureState"
|
||||
},
|
||||
{
|
||||
"name": "core:StatusState"
|
||||
}
|
||||
],
|
||||
"commands": [],
|
||||
"uiClass": "TemperatureSensor",
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer"
|
||||
},
|
||||
{
|
||||
"name": "core:PowerSourceType"
|
||||
},
|
||||
{
|
||||
"name": "core:MeasuredValueType"
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision"
|
||||
}
|
||||
],
|
||||
"widgetName": "TemperatureSensor"
|
||||
},
|
||||
"controllableName": "io:TemperatureInCelciusIOSystemDeviceSensor",
|
||||
"label": "Ventilation (Ventilation#4)",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:StatusState",
|
||||
"value": "available",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:TemperatureState",
|
||||
"value": 19,
|
||||
"type": 2
|
||||
}
|
||||
],
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer",
|
||||
"value": "Atlantic Group",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:PowerSourceType",
|
||||
"value": "mainSupply",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:MeasuredValueType",
|
||||
"value": "core:TemperatureInCelcius",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision",
|
||||
"value": "682008A",
|
||||
"type": 3
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": 2,
|
||||
"synced": true,
|
||||
"enabled": true,
|
||||
"deviceURL": "io://1234-5678-6508/2840629#5",
|
||||
"subsystemId": 5,
|
||||
"available": true,
|
||||
"definition": {
|
||||
"type": "SENSOR",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:TemperatureState"
|
||||
},
|
||||
{
|
||||
"name": "core:StatusState"
|
||||
}
|
||||
],
|
||||
"commands": [],
|
||||
"uiClass": "TemperatureSensor",
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer"
|
||||
},
|
||||
{
|
||||
"name": "core:PowerSourceType"
|
||||
},
|
||||
{
|
||||
"name": "core:MeasuredValueType"
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision"
|
||||
}
|
||||
],
|
||||
"widgetName": "TemperatureSensor"
|
||||
},
|
||||
"controllableName": "io:TemperatureInCelciusIOSystemDeviceSensor",
|
||||
"label": "Ventilation (Ventilation#5)",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:StatusState",
|
||||
"value": "available",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:TemperatureState",
|
||||
"value": 19.2,
|
||||
"type": 2
|
||||
}
|
||||
],
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer",
|
||||
"value": "Atlantic Group",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:PowerSourceType",
|
||||
"value": "mainSupply",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:MeasuredValueType",
|
||||
"value": "core:TemperatureInCelcius",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision",
|
||||
"value": "682008A",
|
||||
"type": 3
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": 2,
|
||||
"synced": true,
|
||||
"enabled": true,
|
||||
"deviceURL": "io://1234-5678-6508/2840629#6",
|
||||
"subsystemId": 6,
|
||||
"available": true,
|
||||
"definition": {
|
||||
"type": "SENSOR",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:TemperatureState"
|
||||
},
|
||||
{
|
||||
"name": "core:StatusState"
|
||||
}
|
||||
],
|
||||
"commands": [],
|
||||
"uiClass": "TemperatureSensor",
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer"
|
||||
},
|
||||
{
|
||||
"name": "core:PowerSourceType"
|
||||
},
|
||||
{
|
||||
"name": "core:MeasuredValueType"
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision"
|
||||
}
|
||||
],
|
||||
"widgetName": "TemperatureSensor"
|
||||
},
|
||||
"controllableName": "io:TemperatureInCelciusIOSystemDeviceSensor",
|
||||
"label": "Ventilation (Ventilation#6)",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:StatusState",
|
||||
"value": "available",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:TemperatureState",
|
||||
"value": 23.1,
|
||||
"type": 2
|
||||
}
|
||||
],
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer",
|
||||
"value": "Atlantic Group",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:PowerSourceType",
|
||||
"value": "mainSupply",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:MeasuredValueType",
|
||||
"value": "core:TemperatureInCelcius",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision",
|
||||
"value": "682008A",
|
||||
"type": 3
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": 2,
|
||||
"synced": true,
|
||||
"enabled": true,
|
||||
"deviceURL": "io://1234-5678-6508/2840629#7",
|
||||
"subsystemId": 7,
|
||||
"available": true,
|
||||
"definition": {
|
||||
"type": "SENSOR",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:TemperatureState"
|
||||
},
|
||||
{
|
||||
"name": "core:StatusState"
|
||||
}
|
||||
],
|
||||
"commands": [],
|
||||
"uiClass": "TemperatureSensor",
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer"
|
||||
},
|
||||
{
|
||||
"name": "core:PowerSourceType"
|
||||
},
|
||||
{
|
||||
"name": "core:MeasuredValueType"
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision"
|
||||
}
|
||||
],
|
||||
"widgetName": "TemperatureSensor"
|
||||
},
|
||||
"controllableName": "io:TemperatureInCelciusIOSystemDeviceSensor",
|
||||
"label": "Ventilation (Ventilation#7)",
|
||||
"states": [
|
||||
{
|
||||
"name": "core:StatusState",
|
||||
"value": "available",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:TemperatureState",
|
||||
"value": 25,
|
||||
"type": 2
|
||||
}
|
||||
],
|
||||
"attributes": [
|
||||
{
|
||||
"name": "core:Manufacturer",
|
||||
"value": "Atlantic Group",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:PowerSourceType",
|
||||
"value": "mainSupply",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:MeasuredValueType",
|
||||
"value": "core:TemperatureInCelcius",
|
||||
"type": 3
|
||||
},
|
||||
{
|
||||
"name": "core:FirmwareRevision",
|
||||
"value": "682008A",
|
||||
"type": 3
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"gateways": [
|
||||
|
||||
@@ -832,3 +832,92 @@
|
||||
'state': 'heat',
|
||||
})
|
||||
# ---
|
||||
# name: test_climate_entities_snapshot[local_somfy_tahoma_switch_europe.json][climate.ventilation-entry]
|
||||
EntityRegistryEntrySnapshot({
|
||||
'aliases': list([
|
||||
None,
|
||||
]),
|
||||
'area_id': None,
|
||||
'capabilities': dict({
|
||||
<ClimateEntityCapabilityAttribute.FAN_MODES: 'fan_modes'>: list([
|
||||
'auto',
|
||||
'away',
|
||||
'home_boost',
|
||||
'kitchen_boost',
|
||||
'bypass_boost',
|
||||
]),
|
||||
<ClimateEntityCapabilityAttribute.HVAC_MODES: 'hvac_modes'>: list([
|
||||
<HVACMode.FAN_ONLY: 'fan_only'>,
|
||||
]),
|
||||
<ClimateEntityCapabilityAttribute.MAX_TEMP: 'max_temp'>: 35,
|
||||
<ClimateEntityCapabilityAttribute.MIN_TEMP: 'min_temp'>: 7,
|
||||
<ClimateEntityCapabilityAttribute.PRESET_MODES: 'preset_modes'>: list([
|
||||
'auto',
|
||||
'prog',
|
||||
'manual',
|
||||
]),
|
||||
}),
|
||||
'config_entry_id': <ANY>,
|
||||
'config_subentry_id': <ANY>,
|
||||
'device_class': None,
|
||||
'device_id': <ANY>,
|
||||
'disabled_by': None,
|
||||
'domain': 'climate',
|
||||
'entity_category': None,
|
||||
'entity_id': 'climate.ventilation',
|
||||
'has_entity_name': True,
|
||||
'hidden_by': None,
|
||||
'icon': None,
|
||||
'id': <ANY>,
|
||||
'labels': set({
|
||||
}),
|
||||
'name': None,
|
||||
'object_id_base': None,
|
||||
'options': dict({
|
||||
}),
|
||||
'original_device_class': None,
|
||||
'original_icon': None,
|
||||
'original_name': None,
|
||||
'platform': 'overkiz',
|
||||
'previous_unique_id': None,
|
||||
'suggested_object_id': None,
|
||||
'supported_features': <ClimateEntityFeature: 408>,
|
||||
'translation_key': 'overkiz',
|
||||
'unique_id': 'io://1234-5678-6508/2840629#1',
|
||||
'unit_of_measurement': None,
|
||||
})
|
||||
# ---
|
||||
# name: test_climate_entities_snapshot[local_somfy_tahoma_switch_europe.json][climate.ventilation-state]
|
||||
StateSnapshot({
|
||||
'attributes': ReadOnlyDict({
|
||||
<ClimateEntityStateAttribute.CURRENT_TEMPERATURE: 'current_temperature'>: 19,
|
||||
<ClimateEntityStateAttribute.FAN_MODE: 'fan_mode'>: 'auto',
|
||||
<ClimateEntityCapabilityAttribute.FAN_MODES: 'fan_modes'>: list([
|
||||
'auto',
|
||||
'away',
|
||||
'home_boost',
|
||||
'kitchen_boost',
|
||||
'bypass_boost',
|
||||
]),
|
||||
<EntityStateAttribute.FRIENDLY_NAME: 'friendly_name'>: 'Ventilation',
|
||||
<ClimateEntityCapabilityAttribute.HVAC_MODES: 'hvac_modes'>: list([
|
||||
<HVACMode.FAN_ONLY: 'fan_only'>,
|
||||
]),
|
||||
<ClimateEntityCapabilityAttribute.MAX_TEMP: 'max_temp'>: 35,
|
||||
<ClimateEntityCapabilityAttribute.MIN_TEMP: 'min_temp'>: 7,
|
||||
<ClimateEntityStateAttribute.PRESET_MODE: 'preset_mode'>: 'auto',
|
||||
<ClimateEntityCapabilityAttribute.PRESET_MODES: 'preset_modes'>: list([
|
||||
'auto',
|
||||
'prog',
|
||||
'manual',
|
||||
]),
|
||||
<EntityStateAttribute.SUPPORTED_FEATURES: 'supported_features'>: <ClimateEntityFeature: 408>,
|
||||
}),
|
||||
'context': <ANY>,
|
||||
'entity_id': 'climate.ventilation',
|
||||
'last_changed': <ANY>,
|
||||
'last_reported': <ANY>,
|
||||
'last_updated': <ANY>,
|
||||
'state': 'fan_only',
|
||||
})
|
||||
# ---
|
||||
|
||||
@@ -12,6 +12,7 @@ from syrupy.assertion import SnapshotAssertion
|
||||
|
||||
from homeassistant.components.climate import (
|
||||
ATTR_CURRENT_TEMPERATURE,
|
||||
ATTR_FAN_MODE,
|
||||
ATTR_HVAC_ACTION,
|
||||
ATTR_PRESET_MODE,
|
||||
HVACAction,
|
||||
@@ -69,12 +70,19 @@ THERMOSTAT_HEATING = FixtureDevice(
|
||||
"io://1234-5678-5010/386310#1",
|
||||
"climate.study_thermostat",
|
||||
)
|
||||
# io:AtlanticHeatRecoveryVentilationIOComponent without io:VentilationModeState value
|
||||
HEAT_RECOVERY_VENTILATION = FixtureDevice(
|
||||
"setup/local_somfy_tahoma_switch_europe.json",
|
||||
"io://1234-5678-6508/2840629#1",
|
||||
"climate.ventilation",
|
||||
)
|
||||
|
||||
SNAPSHOT_FIXTURES = [
|
||||
VALVE,
|
||||
COZYTOUCH,
|
||||
YUTAKI_ZONE_1,
|
||||
THERMOSTAT_HEATING,
|
||||
HEAT_RECOVERY_VENTILATION,
|
||||
]
|
||||
|
||||
|
||||
@@ -390,3 +398,27 @@ async def test_thermostat_heating_set_preset_mode(
|
||||
command_name="setDerogation",
|
||||
parameters=parameters,
|
||||
)
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
("service", "service_data"),
|
||||
[
|
||||
pytest.param("set_fan_mode", {ATTR_FAN_MODE: "bypass_boost"}, id="fan_mode"),
|
||||
pytest.param("set_preset_mode", {ATTR_PRESET_MODE: "prog"}, id="preset_mode"),
|
||||
],
|
||||
)
|
||||
async def test_heat_recovery_ventilation_without_ventilation_mode(
|
||||
hass: HomeAssistant,
|
||||
setup_overkiz_integration: SetupOverkizIntegration,
|
||||
service: str,
|
||||
service_data: dict[str, str],
|
||||
) -> None:
|
||||
"""Test setting modes does not fail without an io:VentilationModeState value."""
|
||||
await setup_overkiz_integration(fixture=HEAT_RECOVERY_VENTILATION.fixture)
|
||||
|
||||
await hass.services.async_call(
|
||||
"climate",
|
||||
service,
|
||||
{"entity_id": HEAT_RECOVERY_VENTILATION.entity_id, **service_data},
|
||||
blocking=True,
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user