I know this is a sticky topic, but in reality it is an extremely important topic.

What have we learnt in the past 3 years.

1/ Understand the type of earthing arrangement.
2/ A permanent neutral/earth bond is not the best solution, in fact as we know having 2 neutral earth bond on one supply is a really bad idea, especially on TN-S systems.
3/ An external relay is also not a smart idea, especially if the bond is made after the changeover switch.
4/ There a big difference between a changeover switch and a bypass switch, understanding where and why it is used is extremely important, especially when dealing with neutral/earth bonding.
5/ Built in (inverter or gateway/changeover panel) neutral/earth bonding on the UPS/inverter/essential input is the key to a safer installation.

This topic should be discussed in a lot more details, considering time delays on certain inverters, especially if an external relay is switched by via a terminal provided in side an inverter.

I am going to say it again, this is not a pissing contest and I encourage people at any level in the electrical/solar industry to share your input, because everyday we keep learning and the only way to improve the safety for our customers is by open discussions.