[Zope3-dev] RolePermissions UI broken

Steve Alexander steve@cat-box.net
Fri, 15 Feb 2002 18:15:45 +0000


Steve Alexander wrote:
> The RolePermissions UI is broken.
> 
> I'm looking into it. So far, I've found out that 
> Zope/App/Security/AttributeRolePermissionManager.py is returning a 
> two-tuple from getRolesForPermission, where according to the interface 
> IRolePermissionMap, it should be returning a simple sequence of roles.

Ok... looking further, this seems to have been broken as part of the 
post-spam10 sprint, with the introduction of Security/LocalSecurityMap.py.

This is quite easy to fix, but in only one of two ways. I need help 
choosing the correct way.

   1: The docstring of getRolesForPermission of IRolePermissionMap should
      be changed to say that it returns a sequence of two-tuple rather
      than a sequence of roles. The code should be made consistent with
      this interface.

   2: AttributeRolePermissionManager.py is changed to comply with the
      contract of the interface it claims to implement.

--
Steve Alexander