Fix autoreset timeout during partial adaptation

This commit is contained in:
Bas Nijholt 2026-09-06 01:31:45 -07:00
commit c05587a092
2 changed files with 82 additions and 3 deletions

View file

@ -2497,9 +2497,11 @@ class AdaptiveLightingManager:
if (
timer is not None
and timer.is_running()
and not is_our_context(event.context)
and not self.is_proactively_adapting(event.context.id)
and event.time_fired > timer.start_time # type: ignore[operator]
):
# Restart the auto reset timer
# Only external turn-ons extend manual control, not our adaptations.
timer.start()
if service == SERVICE_TURN_OFF: