From aa5e4d5062d5e2db5c2020cf09d7a66fa9e72b43 Mon Sep 17 00:00:00 2001 From: Richard West Date: Thu, 7 Feb 2019 09:44:51 -0500 Subject: [PATCH] More helpful debugging message in databaseTest. Tells you which group caused the problem molecule. --- testing/databaseTest.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/testing/databaseTest.py b/testing/databaseTest.py index 1d566d5273a..e05b508d488 100644 --- a/testing/databaseTest.py +++ b/testing/databaseTest.py @@ -1035,8 +1035,11 @@ def general_checkSampleDescendsToGroup(self, group_name, group): for entryName, entry in group.entries.iteritems(): try: if isinstance(entry.item, Group): - sampleMolecule = entry.item.makeSampleMolecule() - + try: + sampleMolecule = entry.item.makeSampleMolecule() + except: + logging.error("Problem making sample molecule for group {}\n{}".format(entryName, entry.item.toAdjacencyList())) + raise #for now ignore sample atoms that use nitrogen types nitrogen = False for atom in sampleMolecule.atoms: