Bump ZHA dependencies (#105661)
This commit is contained in:
parent
db52b9b0e1
commit
ebb54d7a6c
7 changed files with 13 additions and 69 deletions
|
@ -139,7 +139,6 @@ CONF_ENABLE_IDENTIFY_ON_JOIN = "enable_identify_on_join"
|
|||
CONF_ENABLE_QUIRKS = "enable_quirks"
|
||||
CONF_RADIO_TYPE = "radio_type"
|
||||
CONF_USB_PATH = "usb_path"
|
||||
CONF_USE_THREAD = "use_thread"
|
||||
CONF_ZIGPY = "zigpy_config"
|
||||
|
||||
CONF_CONSIDER_UNAVAILABLE_MAINS = "consider_unavailable_mains"
|
||||
|
|
|
@ -46,7 +46,6 @@ from .const import (
|
|||
ATTR_SIGNATURE,
|
||||
ATTR_TYPE,
|
||||
CONF_RADIO_TYPE,
|
||||
CONF_USE_THREAD,
|
||||
CONF_ZIGPY,
|
||||
DEBUG_COMP_BELLOWS,
|
||||
DEBUG_COMP_ZHA,
|
||||
|
@ -158,15 +157,6 @@ class ZHAGateway:
|
|||
if CONF_NWK_VALIDATE_SETTINGS not in app_config:
|
||||
app_config[CONF_NWK_VALIDATE_SETTINGS] = True
|
||||
|
||||
# The bellows UART thread sometimes propagates a cancellation into the main Core
|
||||
# event loop, when a connection to a TCP coordinator fails in a specific way
|
||||
if (
|
||||
CONF_USE_THREAD not in app_config
|
||||
and radio_type is RadioType.ezsp
|
||||
and app_config[CONF_DEVICE][CONF_DEVICE_PATH].startswith("socket://")
|
||||
):
|
||||
app_config[CONF_USE_THREAD] = False
|
||||
|
||||
# Local import to avoid circular dependencies
|
||||
# pylint: disable-next=import-outside-toplevel
|
||||
from homeassistant.components.homeassistant_hardware.silabs_multiprotocol_addon import (
|
||||
|
|
|
@ -21,13 +21,13 @@
|
|||
"universal_silabs_flasher"
|
||||
],
|
||||
"requirements": [
|
||||
"bellows==0.37.1",
|
||||
"bellows==0.37.3",
|
||||
"pyserial==3.5",
|
||||
"pyserial-asyncio==0.6",
|
||||
"zha-quirks==0.0.107",
|
||||
"zigpy-deconz==0.22.0",
|
||||
"zigpy==0.60.0",
|
||||
"zigpy-xbee==0.20.0",
|
||||
"zigpy-deconz==0.22.2",
|
||||
"zigpy==0.60.1",
|
||||
"zigpy-xbee==0.20.1",
|
||||
"zigpy-zigate==0.12.0",
|
||||
"zigpy-znp==0.12.0",
|
||||
"universal-silabs-flasher==0.0.15",
|
||||
|
|
|
@ -10,7 +10,6 @@ import logging
|
|||
import os
|
||||
from typing import Any, Self
|
||||
|
||||
from bellows.config import CONF_USE_THREAD
|
||||
import voluptuous as vol
|
||||
from zigpy.application import ControllerApplication
|
||||
import zigpy.backups
|
||||
|
@ -175,7 +174,6 @@ class ZhaRadioManager:
|
|||
app_config[CONF_DATABASE] = database_path
|
||||
app_config[CONF_DEVICE] = self.device_settings
|
||||
app_config[CONF_NWK_BACKUP_ENABLED] = False
|
||||
app_config[CONF_USE_THREAD] = False
|
||||
app_config = self.radio_type.controller.SCHEMA(app_config)
|
||||
|
||||
app = await self.radio_type.controller.new(
|
||||
|
|
|
@ -523,7 +523,7 @@ beautifulsoup4==4.12.2
|
|||
# beewi-smartclim==0.0.10
|
||||
|
||||
# homeassistant.components.zha
|
||||
bellows==0.37.1
|
||||
bellows==0.37.3
|
||||
|
||||
# homeassistant.components.bmw_connected_drive
|
||||
bimmer-connected[china]==0.14.6
|
||||
|
@ -2825,10 +2825,10 @@ zhong-hong-hvac==1.0.9
|
|||
ziggo-mediabox-xl==1.1.0
|
||||
|
||||
# homeassistant.components.zha
|
||||
zigpy-deconz==0.22.0
|
||||
zigpy-deconz==0.22.2
|
||||
|
||||
# homeassistant.components.zha
|
||||
zigpy-xbee==0.20.0
|
||||
zigpy-xbee==0.20.1
|
||||
|
||||
# homeassistant.components.zha
|
||||
zigpy-zigate==0.12.0
|
||||
|
@ -2837,7 +2837,7 @@ zigpy-zigate==0.12.0
|
|||
zigpy-znp==0.12.0
|
||||
|
||||
# homeassistant.components.zha
|
||||
zigpy==0.60.0
|
||||
zigpy==0.60.1
|
||||
|
||||
# homeassistant.components.zoneminder
|
||||
zm-py==0.5.2
|
||||
|
|
|
@ -445,7 +445,7 @@ base36==0.1.1
|
|||
beautifulsoup4==4.12.2
|
||||
|
||||
# homeassistant.components.zha
|
||||
bellows==0.37.1
|
||||
bellows==0.37.3
|
||||
|
||||
# homeassistant.components.bmw_connected_drive
|
||||
bimmer-connected[china]==0.14.6
|
||||
|
@ -2114,10 +2114,10 @@ zeversolar==0.3.1
|
|||
zha-quirks==0.0.107
|
||||
|
||||
# homeassistant.components.zha
|
||||
zigpy-deconz==0.22.0
|
||||
zigpy-deconz==0.22.2
|
||||
|
||||
# homeassistant.components.zha
|
||||
zigpy-xbee==0.20.0
|
||||
zigpy-xbee==0.20.1
|
||||
|
||||
# homeassistant.components.zha
|
||||
zigpy-zigate==0.12.0
|
||||
|
@ -2126,7 +2126,7 @@ zigpy-zigate==0.12.0
|
|||
zigpy-znp==0.12.0
|
||||
|
||||
# homeassistant.components.zha
|
||||
zigpy==0.60.0
|
||||
zigpy==0.60.1
|
||||
|
||||
# homeassistant.components.zwave_js
|
||||
zwave-js-server-python==0.54.0
|
||||
|
|
|
@ -1,9 +1,8 @@
|
|||
"""Test ZHA Gateway."""
|
||||
import asyncio
|
||||
from unittest.mock import MagicMock, patch
|
||||
from unittest.mock import patch
|
||||
|
||||
import pytest
|
||||
from zigpy.application import ControllerApplication
|
||||
import zigpy.profiles.zha as zha
|
||||
import zigpy.zcl.clusters.general as general
|
||||
import zigpy.zcl.clusters.lighting as lighting
|
||||
|
@ -223,48 +222,6 @@ async def test_gateway_create_group_with_id(
|
|||
assert zha_group.group_id == 0x1234
|
||||
|
||||
|
||||
@patch(
|
||||
"homeassistant.components.zha.core.gateway.ZHAGateway.async_load_devices",
|
||||
MagicMock(),
|
||||
)
|
||||
@patch(
|
||||
"homeassistant.components.zha.core.gateway.ZHAGateway.async_load_groups",
|
||||
MagicMock(),
|
||||
)
|
||||
@pytest.mark.parametrize(
|
||||
("device_path", "thread_state", "config_override"),
|
||||
[
|
||||
("/dev/ttyUSB0", True, {}),
|
||||
("socket://192.168.1.123:9999", False, {}),
|
||||
("socket://192.168.1.123:9999", True, {"use_thread": True}),
|
||||
],
|
||||
)
|
||||
async def test_gateway_initialize_bellows_thread(
|
||||
device_path: str,
|
||||
thread_state: bool,
|
||||
config_override: dict,
|
||||
hass: HomeAssistant,
|
||||
zigpy_app_controller: ControllerApplication,
|
||||
config_entry: MockConfigEntry,
|
||||
) -> None:
|
||||
"""Test ZHA disabling the UART thread when connecting to a TCP coordinator."""
|
||||
config_entry.data = dict(config_entry.data)
|
||||
config_entry.data["device"]["path"] = device_path
|
||||
config_entry.add_to_hass(hass)
|
||||
|
||||
zha_gateway = ZHAGateway(hass, {"zigpy_config": config_override}, config_entry)
|
||||
|
||||
with patch(
|
||||
"bellows.zigbee.application.ControllerApplication.new",
|
||||
return_value=zigpy_app_controller,
|
||||
) as mock_new:
|
||||
await zha_gateway.async_initialize()
|
||||
|
||||
mock_new.mock_calls[-1].kwargs["config"]["use_thread"] is thread_state
|
||||
|
||||
await zha_gateway.shutdown()
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
("device_path", "config_override", "expected_channel"),
|
||||
[
|
||||
|
|
Loading…
Add table
Reference in a new issue