Author: tmckay
Date: 2012-05-11 16:13:30 +0000 (Fri, 11 May 2012)
New Revision: 5373
Modified:
trunk/cumin/python/cumin/authenticator.py
Log:
If an exception on ldap search returns "" on str(), use e.__repr__()
Modified: trunk/cumin/python/cumin/authenticator.py
===================================================================
--- trunk/cumin/python/cumin/authenticator.py 2012-05-10 20:44:07 UTC (rev 5372)
+++ trunk/cumin/python/cumin/authenticator.py 2012-05-11 16:13:30 UTC (rev 5373)
@@ -145,8 +145,11 @@
try:
res = conn.search_s(self.url.dn, self.url.scope, filter)
except Exception, e:
+ msg = str(e)
+ if not msg:
+ msg = e.__repr__()
log.error("Authenticator: find_user, "\
- "query returned exception %s", e)
+ "query returned exception %s" % msg)
return conn, res
def find_user(self, user):
Show replies by date