Skip to content

Track devices that join the network after startup - #157

Open
LightD31 wants to merge 2 commits into
HarvsG:masterfrom
LightD31:pr2-device-tracker-new-devices
Open

Track devices that join the network after startup#157
LightD31 wants to merge 2 commits into
HarvsG:masterfrom
LightD31:pr2-device-tracker-new-devices

Conversation

@LightD31

Copy link
Copy Markdown

GLinetRouter dispatches signal_device_new when polling finds a client it has not seen before (router.py:368), but device_tracker.async_setup_entry never subscribed to it. It called update_router() once at setup and then nothing again.

The effect: devices that join the network after Home Assistant starts get no tracker entity until the config entry is reloaded or HA restarts.

This connects update_router to the signal, unsubscribing on unload. Independent of PR 1; a test covering it comes with the test-suite PR.

claude added 2 commits July 26, 2026 21:43
This repository was started from a component template and some strings
still name the components it was copied from:

- pyproject.toml describes the project as the Google Home integration
- the prettier pre-commit hook excludes custom_components/google_home/
  manifest.json, a path that does not exist here, so glinet's
  manifest.json is not actually excluded
- button.py and switch.py carry Pi-hole module and function docstrings

No behaviour changes.
GLinetRouter dispatches signal_device_new when polling finds a client it
has not seen before (router.py:368), but device_tracker.async_setup_entry
never subscribed to it: it called update_router() once at setup and then
nothing again. Devices that joined the network later got no tracker
entity until the config entry was reloaded or Home Assistant restarted.

Connect update_router to the signal, unsubscribing on unload.
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.

2 participants