Roland Hedberg wrote: >> I have something slightly more efficient based on evaluating >> hasSubordinates or similar attributes for sub-tree deletion in web2ldap. > > If you are willing to share I'd love to have it :-)
Hmm, look into web2ldap's source (GPL): function DelTree() in pylib/w2lapp/delete.py. But it's not in a shape to directly use it. It's more munged into the application. And the hasSubordinates handling is slightly different from what you need. It rather trys to delete a whole entry and retries differently after receiving ldap.NOT_ALLOWED_ON_NONLEAF. Hmm, glancing over the code I'd suggest to implement it separately. I'd try to rename the whole sub-tree first and then handle ldap.NOT_ALLOWED_ON_NONLEAF smoothly. Ciao, Michael. ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Python-LDAP-dev mailing list Python-LDAP-dev@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/python-ldap-dev