@@ -141,6 +141,11 @@ async def initialize(self) -> None:
141
141
)
142
142
self .fabric_id_hex = hex (self .compressed_fabric_id )[2 :]
143
143
LOGGER .debug ("CHIP Device Controller Initialized" )
144
+ LOGGER .info (
145
+ "Compressed Fabric ID: %s - HEX: %s" ,
146
+ self .compressed_fabric_id ,
147
+ self .fabric_id_hex ,
148
+ )
144
149
145
150
async def start (self ) -> None :
146
151
"""Handle logic on controller start."""
@@ -180,13 +185,15 @@ async def start(self) -> None:
180
185
self .server .storage .remove (DATA_KEY_NODES , node_id_str )
181
186
LOGGER .info ("Loaded %s nodes from stored configuration" , len (self ._nodes ))
182
187
# set-up mdns browser
188
+ LOGGER .info ("Starting mdns discovery...." )
183
189
self ._aiozc = AsyncZeroconf (ip_version = IPVersion .All )
184
190
services = [MDNS_TYPE_OPERATIONAL_NODE , MDNS_TYPE_COMMISSIONABLE_NODE ]
185
191
self ._aiobrowser = AsyncServiceBrowser (
186
192
self ._aiozc .zeroconf ,
187
193
services ,
188
194
handlers = [self ._on_mdns_service_state_change ],
189
195
)
196
+ LOGGER .info ("Mdns discovery initialized...." )
190
197
191
198
async def stop (self ) -> None :
192
199
"""Handle logic on server stop."""
@@ -1168,10 +1175,14 @@ def _on_mdns_service_state_change(
1168
1175
return
1169
1176
if service_type == MDNS_TYPE_OPERATIONAL_NODE :
1170
1177
name = name .lower ()
1178
+ LOGGER .info ("Received %s MDNS event for %s" , state_change , name )
1171
1179
if not name .startswith (self .fabric_id_hex ):
1172
1180
# filter out messages that are not for our fabric
1181
+ LOGGER .warning (
1182
+ "Ignore MDNS event for %s due to a fabric mismatch" , name
1183
+ )
1173
1184
return
1174
- LOGGER . debug ( "Received %s MDNS event for %s" , state_change , name )
1185
+
1175
1186
if state_change not in (
1176
1187
ServiceStateChange .Added ,
1177
1188
ServiceStateChange .Updated ,
0 commit comments