zigpy / open-coordinator-backup

Open Zigbee coordinator backup format
MIT License
56 stars 7 forks source link

Update `is_child` description #7

Closed castorw closed 2 years ago

castorw commented 2 years ago

Hi @puddly, I looked over the updated related to is_child key and I think we should consider the default value to be always true if the field is not provided (undefined). From what I understand the presence of link_key for the device has nothing to do with this and we should choose default value based on this.

The link key is always exchanged between device and coordinator agnostic of the number of routers in the way. So its presence does not give you grounds to determine default value for the Assoc flag. I think we should default to true since it does not seem to break the network and we cannot reliably determine its value if not explicitly provided.

puddly commented 2 years ago

Yes, you are correct. I originally worded it to ensure backwards compatibility when the key is missing but let's go with the correct behavior.