Skip to content

feat(discovery): add discover_devices_stream streaming variant - #54

Merged
Irishsmurf merged 4 commits into
mainfrom
feat/discover-devices-stream
Jun 13, 2026
Merged

Irishsmurf merged 4 commits into
mainfrom
feat/discover-devices-stream

Conversation

@Irishsmurf

Copy link
Copy Markdown
Owner

Closes #33

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces discover_devices_stream, an asynchronous generator that yields discovered dLight devices incrementally as they respond. It also updates the documentation and adds unit tests for this new feature. The reviewer feedback highlights a potential data loss issue in the streaming loop if consumer processing delays cause a timeout, suggesting yielding all buffered devices before exiting. Additionally, the reviewer suggests making the results_list parameter optional in _DiscoveryProtocol to avoid unnecessary list allocations during streaming discovery.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread dlightclient/discovery.py
Comment thread dlightclient/discovery.py
Comment thread dlightclient/discovery.py
Comment thread dlightclient/discovery.py
Comment thread dlightclient/discovery.py
@Irishsmurf
Irishsmurf merged commit 290bb2d into main Jun 13, 2026
5 checks passed
@Irishsmurf
Irishsmurf deleted the feat/discover-devices-stream branch June 13, 2026 22:17
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.

discover_devices(): streaming async generator variant

1 participant