handle LDAP search exceptions in datasource-ldap.py