[Zope3-dev] RolePermissions UI broken

Casey Duncan casey_duncan@yahoo.com
Fri, 15 Feb 2002 10:39:56 -0800 (PST)


The interface should be changed. The behavior of
returning the two tuple is correct. The tuple consists
of (role_id, setting)

Where is setting is Assign, Remove or Unset (defined
in App.Security.Settings). This allows you to assert
that a role is removed lower down in the hierarchy in
a certain area.

I will make this change and make sure the other
interfaces are consistent with the new data structure.

-Casey

--- Steve Alexander <steve@cat-box.net> wrote:
> 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
> 
> 
> 
> _______________________________________________
> Zope3-dev mailing list
> Zope3-dev@zope.org
> http://lists.zope.org/mailman/listinfo/zope3-dev
> 
> 


__________________________________________________
Do You Yahoo!?
Got something to say? Say it better with Yahoo! Video Mail 
http://mail.yahoo.com