[Zope] permissionsOfRole

Ivan Raikov ivan@faxnet.com
Fri, 24 Aug 2001 09:41:23 -0400


Hello,

	I have the following situation: in a custom Folder object,
there's a permissionsOfRole method, which is a slightly modified form
of the original in AccessControl.Role in that it filters out all the
permissions that do not belong to my product (and their names have a
certain prefix, so that they can be distinguished from the default
Zope permissions). 

     I'm also using the roleEdit DTML file from the Zope
distribution. It uses the permissionsOfRole method in order to present
the user with all permissions that are assigned to a certain
user-defined role, and, in my case it finds the modified
permissionsOfRole method via acquisition, and correctly displays only
the permissions that have been defined within my product.

     I also have a piece of code that tries to retrieve all the
permissions for a certain role from within an object that's contained
in the aforementioned custom Folder. When this code calls
self.permissionsOfRole on a role that has been successfully edited via
the DTML form, it receives strange results: the user-defined role
appears to have _no_ permissions associated with it, although it has
just been edited via the DTML interface. I tried creating new roles
multiple times, but whenever I call permissionsOfRole
programmatically, I get an empty set of permissions.

     Has anyone experienced similar problems with permissionsOfRole?
Please let me know...



       Regards,
       Ivan Raikov