collective / collective.volto.formsupport

Enable support for customizable forms in Volto
GNU General Public License v2.0
2 stars 8 forks source link

AttributeError: 'MemberData' object has no attribute 'allowed' #8

Closed tisto closed 3 years ago

tisto commented 3 years ago

I installed c.v.formsupport in a Plone 5.2.4 buildout (added to eggs in "instance" section, then run buildout). When I fire up the backend instance, install the add-on and then access Volto on the portal root, I see the following traceback on the backend:

2021-10-20 22:02:41,655 ERROR   [Zope.SiteErrorLog:22][waitress-1] AttributeError: http://localhost:3000/blocks-misc/GET_application_json_
Traceback (innermost last):
  Module ZPublisher.WSGIPublisher, line 162, in transaction_pubevents
  Module ZPublisher.WSGIPublisher, line 371, in publish_module
  Module ZPublisher.WSGIPublisher, line 266, in publish
  Module ZPublisher.mapply, line 85, in mapply
  Module ZPublisher.WSGIPublisher, line 63, in call_object
  Module plone.rest.service, line 22, in __call__
  Module plone.restapi.services, line 19, in render
  Module plone.restapi.services.content.get, line 16, in reply
  Module plone.restapi.serializer.dxcontent, line 150, in __call__
  Module plone.restapi.serializer.dxcontent, line 87, in __call__
  Module plone.restapi.serializer.expansion, line 14, in expandable_elements
  Module collective.volto.formsupport.restapi.services.form_data.form_data, line 24, in __call__
  Module collective.volto.formsupport.restapi.services.form_data.form_data, line 49, in show_component
  Module <decorator-gen-37>, line 2, in has_permission
  Module plone.api.validation, line 116, in wrapped
  Module plone.api.user, line 339, in has_permission
  Module AccessControl.ImplPython, line 522, in checkPermission
AttributeError: 'MemberData' object has no attribute 'allowed'
cekk commented 3 years ago

this seems related to zope admin user: i don't know why we can't check his permissions. btw i have this error on a 5.2.4 installation (the volto api buildout) but upgrading it to 5.2.6 it works.

Another strange thing is that on other 5.2.4 instances (different projects) it still works..probably something changed in some low-level dependency that we're using in that buildout (the volto one)?

cekk commented 3 years ago

Released v2.0.2