Skip to content

Commit a301ed3

Browse files
committed
Retry adding descriptive docstring
1 parent 576dc34 commit a301ed3

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

plugwise_usb/network/registry.py

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,19 @@ def start_node_discover(
106106
self._start_node_discover = callback
107107

108108
def scan_completed_callback(self, callback: Callable[[], Awaitable[None]]) -> None:
109-
"""Register method to be called when a registry scan has completed."""
109+
"""Register async callback invoked when a node is found.
110+
111+
Args:
112+
callback: Async callable with signature
113+
(mac: str, node_type: NodeType | None, ping_first: bool) -> bool.
114+
It must return True when discovery succeeded; return False to allow the caller
115+
to fall back (e.g., SED discovery path).
116+
117+
Returns:
118+
None
119+
120+
"""
121+
110122
self._scan_completed_callback = callback
111123

112124
async def _exec_node_discover_callback(

0 commit comments

Comments
 (0)