I do think this is an oversight in the Zigbee specification. It would be helpful to have an intermediate “unreliably mains powered” device type that could participate in mesh networking between routers when powered but would be selected by end devices as a router only as a last resort.
I also struggled with this issue. I have 40+ light sources, most of them behind a dumb switch, some even behind 4 dumb switches (hallway lights). I had constant issues with end devices stopping to work - temperature sensors, window sensors, remotes, smart thermostat valves.
The electrical installation was designed without taking “smart” into account and while I’m thinking about replacing the switches in the hallway, where I use motion sensors, I can’t be bothered with replacing those dumb switches everywhere, no thank you.
So this is a solution I came up with. I’m using it for only a week now and things are much more stable. I would even say “stable, period”, but I need to give it more time to know for sure.
I now have two Zigbee networks with two coordinators connected to my HA raspberry pi.
The first network - using SkyConnect - is controlled with ZHA and has all those unreliably powered light sources connected and some other mains powered devices I don’t trust enough to put on the “stable” network (mostly sockets). I also keep Phillips hue dimmers and some Ikea remotes in this network for now as the blueprint I use for them doesn’t seem to work properly when the remote is in zigbee2mqtt, which the new network uses. But when I fix that, I’ll move all of them to the second network.
The second network is using a Sonoff dongle and is controlled by zigbee2mqtt (you can’t control 2 dongles with ZHA anyway). The backbone of this network is made from Ikea mains powered devices that are not behind any dumb switch (except for the circuit breaker, etc) - a light bulb, two 30W drivers, several smart sockets and 5 Tradfri signal repeaters. I moved most end devices to this network (except for the remotes mentioned before).
Not having to debug breaking automations almost every day is such a relief. But yeah, it would be much better if it was so stable without having to jump through hoops like that.
Edit: typo