MDL-42863 make capabilities overview more fault-tolerant.
MDL-42865 Make XMLDB foreign key check more robust.

Otherwise, installing one bad add-on can completely break this report.