# HG changeset patch # User Alexandre Fayolle # Date 1275127430 0 # Node ID 60a92bf32a18669d5f39f5e0edc5ca75560a9fa5 # Parent d8d9f4ec252d4612da5dd957520af736cd09e5b6 ldap: reset cache when a user is deleted When a user is deleted from ldap, reset both caches used by the source otherwise the search is not performed again and exceptions such as UnknownEid: No entity with eid 74078 in the repository will occur diff -r d8d9f4ec252d -r 60a92bf32a18 server/sources/ldapuser.py --- a/server/sources/ldapuser.py Sat May 29 09:58:23 2010 +0000 +++ b/server/sources/ldapuser.py Sat May 29 10:03:50 2010 +0000 @@ -513,7 +513,7 @@ eid, base) entity = session.entity_from_eid(eid, 'CWUser') self.repo.delete_info(session, entity, self.uri, base) - self._cache.pop(base, None) + self.reset_cache() return [] ## except ldap.REFERRAL, e: ## cnx = self.handle_referral(e)