Add parallel updates to Fritz (#142409)
* Add parallel updates to Fritz * apply review comment * tweakpull/142338/head^2
parent
9a897d5e12
commit
e96f2f06fb
|
@ -20,6 +20,9 @@ from .entity import FritzBoxBaseCoordinatorEntity, FritzEntityDescription
|
|||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
# Coordinator is used to centralize the data updates
|
||||
PARALLEL_UPDATES = 0
|
||||
|
||||
|
||||
@dataclass(frozen=True, kw_only=True)
|
||||
class FritzBinarySensorEntityDescription(
|
||||
|
|
|
@ -31,6 +31,9 @@ from .entity import FritzDeviceBase
|
|||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
# Set a sane value to avoid too many updates
|
||||
PARALLEL_UPDATES = 5
|
||||
|
||||
|
||||
@dataclass(frozen=True, kw_only=True)
|
||||
class FritzButtonDescription(ButtonEntityDescription):
|
||||
|
|
|
@ -22,6 +22,9 @@ from .entity import FritzDeviceBase
|
|||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
# Coordinator is used to centralize the data updates
|
||||
PARALLEL_UPDATES = 0
|
||||
|
||||
|
||||
async def async_setup_entry(
|
||||
hass: HomeAssistant,
|
||||
|
|
|
@ -18,6 +18,9 @@ from .entity import FritzBoxBaseEntity
|
|||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
# Coordinator is used to centralize the data updates
|
||||
PARALLEL_UPDATES = 0
|
||||
|
||||
|
||||
async def async_setup_entry(
|
||||
hass: HomeAssistant,
|
||||
|
|
|
@ -33,9 +33,7 @@ rules:
|
|||
entity-unavailable: done
|
||||
integration-owner: done
|
||||
log-when-unavailable: done
|
||||
parallel-updates:
|
||||
status: todo
|
||||
comment: not set at the moment, we use a coordinator
|
||||
parallel-updates: done
|
||||
reauthentication-flow: done
|
||||
test-coverage:
|
||||
status: todo
|
||||
|
|
|
@ -32,6 +32,9 @@ from .entity import FritzBoxBaseCoordinatorEntity, FritzEntityDescription
|
|||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
# Coordinator is used to centralize the data updates
|
||||
PARALLEL_UPDATES = 0
|
||||
|
||||
|
||||
def _uptime_calculation(seconds_uptime: float, last_value: datetime | None) -> datetime:
|
||||
"""Calculate uptime with deviation."""
|
||||
|
|
|
@ -38,6 +38,9 @@ from .entity import FritzBoxBaseEntity, FritzDeviceBase
|
|||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
# Set a sane value to avoid too many updates
|
||||
PARALLEL_UPDATES = 5
|
||||
|
||||
|
||||
async def _async_deflection_entities_list(
|
||||
avm_wrapper: AvmWrapper, device_friendly_name: str
|
||||
|
|
|
@ -20,6 +20,9 @@ from .entity import FritzBoxBaseCoordinatorEntity, FritzEntityDescription
|
|||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
# Set a sane value to avoid too many updates
|
||||
PARALLEL_UPDATES = 5
|
||||
|
||||
|
||||
@dataclass(frozen=True, kw_only=True)
|
||||
class FritzUpdateEntityDescription(UpdateEntityDescription, FritzEntityDescription):
|
||||
|
|
Loading…
Reference in New Issue