[Zope-dev] manage_permission from script
Erik A.Dahl
edahl at zentinel.com
Wed Apr 7 18:40:20 EDT 2004
I'm trying to use manage_permission from a script against the root
application object. When I do I get the following error from
ObjectManager. This definitely works from within zope since I'm able
to edit permissions from the ZMI. I guess the app object returned from
Zope.app() doesn't have an acquisition wrapper?
-EAD
>>> app.manage_permission("View", ['Owner',], 1)
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/home/edahl/zope-2.7.0/lib/python/AccessControl/Role.py", line
164, in manage_permission
for p in self.ac_inherited_permissions(1):
File "/home/edahl/zope-2.7.0/lib/python/AccessControl/Role.py", line
82, in ac_inherited_permissions
for p in self._subobject_permissions():
File "/home/edahl/zope-2.7.0/lib/python/OFS/ObjectManager.py", line
212, in _subobject_permissions
return (Products.__ac_permissions__+
AttributeError: aq_acquire
More information about the Zope-Dev
mailing list