Hi

I have a script which creates a new instance of a certain portal_type
by a method "constructContent", and then calls manage_setLocalRoles.
And I get an exception:

Module AccessControl.Role, line 362, in manage_setLocalRoles
AttributeError: __hash__

and the lines in question are:
361        dict=self.__ac_local_roles__ or {}
362        dict[userid]=roles

Needless to say, if do the same things (constructContent and
manage_setLocalRoles) one at a time, it works fine. Does this mean
that I should do something in the meantime, after constructContent, to
complete object construction before calling setLocalRoles? Or is there
other way to set local roles on new object?

Bartek
_______________________________________________
Zope-CMF maillist  -  Zope-CMF@lists.zope.org
http://mail.zope.org/mailman/listinfo/zope-cmf

See http://collector.zope.org/CMF for bug reports and feature requests

Reply via email to