File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 99
1010from ..api import NodeType
1111from ..constants import UTF8
12- from ..exceptions import CacheError , NodeError
12+ from ..exceptions import CacheError , NodeError , StickError
1313from ..helpers .util import validate_mac
1414from ..messages .requests import (
1515 CirclePlusScanRequest ,
@@ -257,7 +257,10 @@ async def register_node(self, mac: str) -> None:
257257 raise NodeError (f"MAC '{ mac } ' invalid" )
258258
259259 request = NodeAddRequest (self ._send_to_controller , bytes (mac , UTF8 ), True )
260- await request .send ()
260+ try :
261+ await request .send ()
262+ except StickError as exc :
263+ raise NodeError ("{exc}" ) from exc
261264
262265 async def unregister_node (self , mac : str ) -> None :
263266 """Unregister node from current Plugwise network."""
You can’t perform that action at this time.
0 commit comments