[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Search object exception



jupiter wrote:
> I have a django application which using Python LDAP API

Hmm, this is likely off-topic here.

You're welcome to subscribe to python-ldap mailing list [1] for a more
detailed discussion.

> to search LDAP
> objects and throws object DoesNotExist exception.

You mean ldap.NO_SUCH_OBJECT execption?

> I thought the search
> function should catch the exception, but the owner of the software said,
> the try / except should not be used, if it throws an exception, it is LDAP
> configuration problem, must fix the LDAP configuration.

The questions is why ldap.NO_SUCH_OBJECT is raised. If there's a wrong search
root configured the owner of the software is right.

There could be other reasons. But without knowing the details nobody can tell.

> Is it possible to configure LDAP not throwing exception for searching
> non-existing  objects?

Such a work-around would likely cause more issues than it solves.

You should detail which problem you want to solve.

Ciao, Michael.

[1] https://mail.python.org/mailman/listinfo/python-ldap


Attachment: smime.p7s
Description: S/MIME Cryptographic Signature