[Checkins]
SVN: Products.PluggableAuthService/branches/1.5/Products/PluggableAuthService/
- plugins/ZODBRoleManager: added logging in case searchPrincipial()
Andreas Jung
andreas at andreas-jung.com
Thu Mar 6 04:11:11 EST 2008
Log message for revision 84504:
- plugins/ZODBRoleManager: added logging in case searchPrincipial()
returning more than one result (which might happen in case of
having duplicate id within difference user sources)
Changed:
U Products.PluggableAuthService/branches/1.5/Products/PluggableAuthService/doc/CHANGES.txt
U Products.PluggableAuthService/branches/1.5/Products/PluggableAuthService/plugins/ZODBRoleManager.py
-=-
Modified: Products.PluggableAuthService/branches/1.5/Products/PluggableAuthService/doc/CHANGES.txt
===================================================================
--- Products.PluggableAuthService/branches/1.5/Products/PluggableAuthService/doc/CHANGES.txt 2008-03-06 09:09:27 UTC (rev 84503)
+++ Products.PluggableAuthService/branches/1.5/Products/PluggableAuthService/doc/CHANGES.txt 2008-03-06 09:11:10 UTC (rev 84504)
@@ -7,6 +7,11 @@
- ZODBUserManager plugin: allow unicode arguments to 'enumerateUsers'.
(https://bugs.launchpad.net/zope-pas/+bug/189627)
+ - plugins/ZODBRoleManager: added logging in case searchPrincipial()
+ returning more than one result (which might happen in case of
+ having duplicate id within difference user sources)
+
+
PluggableAuthService 1.5.2.1 (2007/12/07)
Bugs Fixed
Modified: Products.PluggableAuthService/branches/1.5/Products/PluggableAuthService/plugins/ZODBRoleManager.py
===================================================================
--- Products.PluggableAuthService/branches/1.5/Products/PluggableAuthService/plugins/ZODBRoleManager.py 2008-03-06 09:09:27 UTC (rev 84503)
+++ Products.PluggableAuthService/branches/1.5/Products/PluggableAuthService/plugins/ZODBRoleManager.py 2008-03-06 09:11:10 UTC (rev 84504)
@@ -37,6 +37,10 @@
from Products.PluggableAuthService.utils import classImplements
from Products.PluggableAuthService.utils import postonly
+import logging
+
+LOG = logging.getLogger('PluggableAuthService')
+
class IZODBRoleManager(Interface):
""" Marker interface.
"""
@@ -271,7 +275,10 @@
parent = aq_parent( self )
info = parent.searchPrincipals( id=k, exact_match=True )
- assert( len( info ) in ( 0, 1 ) )
+
+ LOG.error('searchPrincipals() returned more than one result '
+ 'for id=%s' % k)
+ assert len(info) <= 1
if len( info ) == 0:
title = '<%s: not found>' % k
else:
More information about the Checkins
mailing list