Ldap.initialize vs. ldap.open [was: Re: Segmention fault on redhat 9 on ldap_simple_bind_s]

Mauro Cicognini mcicogni at siosistemi.it
Wed Oct 1 10:38:08 CEST 2003


Jens Vagelpohl wrote:

> ldap.open is deprecated. Read the docs and use ldap.initialize instead.

May I say that I don't really care for ldap.initialize()? I must have 
missed something, but I really can't understand why the older style 
should be deprecated. What's the real win over using ldap.open()? :-\

To put it in other words, I can't get myself to appreciate LDAP URLs, 
which I find quite cumbersome & complicated. I can never remember 
whether the "sub" argument goes before or after the attribute list, and 
the inability to specify arguments by name (à la Python) is to me a big 
loss. Besides, I am instanciating an LDAP object, so it should be quite 
clear I need an object which talks LDAP, without having to write it 
again in a function argument :-)

IMHO, the LDAP URL only interesting usage is in a browser URL line (in 
fact I strongly suspect is *was* invented for exactly that reason by 
Netscape).

Anyway, there must be some reason, since ldap.open is being deprecated: 
anyone caring to tell me why?

Thanks in advance,
Mauro







More information about the python-ldap mailing list