def delete (self, dn):
        try:
            if settings.LDAP_MASTER_DISABLE == True: return
        except __HOLE__: pass
        try:
            resultid = self.proxy.search(dn, ldap.SCOPE_BASE)
            try:
                t, data = self.proxy.result(resultid, 1)
                logger.debug("LdapProxy.delete: dn %s exists and is going to be deleted" % (dn))
                self.proxy.delete_s(dn)
            except ldap.NO_SUCH_OBJECT:
                pass
        except ldap.LDAPError, error_message:
            logger.error ("ldapproxy: delete %s failed: %s" % (dn, error_message))
            raise
dataset/ETHPy150Open fp7-ofelia/ocf/expedient/src/python/expedient/common/ldapproxy/models.py/LdapProxy.delete