Skip to content

Improve gateway resilience and worker lifecycle management#1

Merged
gPinato merged 1 commit into
masterfrom
fix/listening-loop-resilience
Jun 18, 2026
Merged

Improve gateway resilience and worker lifecycle management#1
gPinato merged 1 commit into
masterfrom
fix/listening-loop-resilience

Conversation

@gPinato

@gPinato gPinato commented Jun 18, 2026

Copy link
Copy Markdown
Owner

Prevent the event listener from crashing the entire integration when it encounters an unconfigured device or unexpected message. Errors during message receive or dispatch are now logged and skipped, while asyncio.CancelledError still propagates for clean HA shutdown.

Also adds proper worker lifecycle via stop() method (from PR anotherjulien#187) so removing and re-adding the integration no longer throws errors from pending tasks.

Includes a test suite with 11 unit tests covering resilience, shutdown, and message queuing.

Prevent the event listener from crashing the entire integration when it
encounters an unconfigured device or unexpected message. Errors during
message receive or dispatch are now logged and skipped, while
asyncio.CancelledError still propagates for clean HA shutdown.

Also adds proper worker lifecycle via stop() method (from PR anotherjulien#187) so
removing and re-adding the integration no longer throws errors from
pending tasks.

Includes a test suite with 11 unit tests covering resilience, shutdown,
and message queuing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@gPinato gPinato merged commit 44b2884 into master Jun 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant