ReconnectLDAPObject doesn't reconnect after main failure

Alain Spineux aspineux at
Sun Jan 28 02:06:47 CET 2007

This is a good point of view!
Anyway I try my _LAST_ arguments.

Python is a language made to help and facilitate the developer work :
- the developer dont need to test the result of any function, python
(or the library) raise an exception if something is wrong.
- the developer dont need to worry about the memory allocation, the
garbage collector do it for him.
- the developer dont need to close a file, the system do it for him
when the object is released
- the developer don't need to worry for long living LDAP connection,
ReconnectLDAPObject  auto reconnect automatically for him :-)
- python-ldap is also thread safe .....

Then why does the developer have to encapsulate any ldap statement into a

except ldap.SERVER_DOWN,e:

whereas	the library can do it for him

Anyway we made a good job !

Tanks for your support.

On 1/27/07, "Michael Ströder" <michael at> wrote:
> On 12:59:58 pm 2007-01-27 "Alain Spineux" <aspineux at> wrote:
> >
> > And what about the idea to put the
> >
> > try:
> > except ldap.SERVER_DOWN,e:
> >    SimpleLDAPObject.unbind_s(self)
> >
> > in the function _ldap_call too ?
> > This will correct also SimpleLDAPObject ?
> There is nothing wrong with SimpleLDAPObject. The application is supposed
> to catch and handle ldap.SERVER_DOWN. Additionally SimpleLDAPObject and
> ReconnectLDAPObject shall behave in the same way. And IMO they do now.
> Ciao, Michael.

Alain Spineux
aspineux gmail com
May the sources be with you

More information about the python-ldap mailing list