Yes, I’ve posted elsewhere about the reed switch as the main component of Xiaomi / Aqara door/window sensors, as a response to some users reporting issues with the contact sensors sending multiple repeated open or closed messages. What I had found is that reed switches react differently depending on the orientation and direction of travel of the activating magnet.
But it would come as no surprise if the low-cost reed switch used in Xiaomi / Aqara sensors can also get damaged during shipping.
Yes, I have considered it, but without spending lots and lots of time recording all ZigBee network traffic data using a ZigBee sniffer device and then spending more time examining it, there isn’t any way to prove or disprove that the hub is not decoding all messages received from Xiaomi / Aqara devices.
This becomes even more complicated if there are repeaters on the network because they will hold/cache messages from the hub to end devices, waiting until battery-powered “sleepy” devices wake up before passing on those messages. Xiaomi / Aqara devices check in far less frequently than other battery-powered ZigBee devices, so it’s totally possible that messages get dropped.
In my own testing, I have seen certain “unfriendly” repeater devices, such as a Securifi Peanut Plug, drop only some messages going from a Xiaomi / Aqara device to the hub. So my educated guess about a lot of the weird connection issues and lack of responsiveness that people have with Xiaomi / Aqara devices is because of repeater devices on the network.
I doubt the code has been changed. All firmware releases include release notes and it would state that there was a change to the ZigBee stack.
The issues you describe do sound just like what happens when a Xiaomi / Aqara device decides to connect via an “unfriendly” repeater.
Are you using an XBee or ZigBee sniffer device to confirm this fact?
Only the newest version of the Samsung Smart Outlet has been reported to work with Xiaomi / Aqara devices, and then Osram outlets / bulbs are not going to allow Xiaomi / Aqara devices to remain connected.
Just because everything works fine for a long time doesn’t mean that Xiaomi / Aqara devices won’t decide to change their connection to an “unfriendly” repeater. All that is needed is some kind of change to the network signals between devices. Then, it also possible that a Xiaomi / Aqara device that drops off the network has trouble being repaired in its location because it’s still trying to connect via that same “unfriendly” repeater. But there’s no way to verify all of this without the use of a ZigBee sniffer recording network traffic the entire time.
However, moving a Xiaomi / Aqara device near the hub just to get it to pair is not a good idea, because if it will be permanently located far from the hub, it really should establish its connection via a (“friendly”) repeater from the start. Pairing ZigBee devices in their intended installation location is just best practice.
Keep in mind that adding “friendly” repeaters does not 100% guarantee your Xiaomi / Aqara devices won’t try to connect via an “unfriendly” one and then drop the connection.
I only have personal experience with the IKEA Tradfri Outlet, and it works just great with Xiaomi / Aqara devices. Other people have reported success with the IKEA Tradfri Signal repeater, but its signal is not as strong so it doesn’t help with as large of an area of the mesh network.
I recommend reading a thread I started for a different but in many ways similar hub platform, Hubitat, which discusses in great detail all things about keeping Xiaomi / Aqara devices connected: