collective / collective.lazysizes

Integration of lazysizes, a lightweight lazy loader, into Plone.
https://pypi.org/project/collective.lazysizes
6 stars 2 forks source link

ComponentLookupError when trying to edit css_class_blacklist in portal_registry #30

Closed fulv closed 7 years ago

fulv commented 7 years ago

I just installed collective.lazysizes 3.0 on Plone 5.0.6.

I went to /portal_registry, searched for "lazy", and clicked on css_class_blacklist.

An error popped up, and I see this in the Zope log:

2017-03-09T12:24:54 ERROR Zope.SiteErrorLog 1489091094.60.0224475098777 http://nonprofits.givesomethingback.com/portal_registry/edit/collective.lazysizes.interfaces.ILazySizesSettings.css_class_blacklist
Traceback (innermost last):
  Module ZPublisher.Publish, line 138, in publish
  Module ZPublisher.mapply, line 77, in mapply
  Module ZPublisher.Publish, line 48, in call_object
  Module plone.z3cform.layout, line 66, in __call__
  Module plone.z3cform.layout, line 50, in update
  Module plone.app.registry.browser.edit, line 27, in update
  Module z3c.form.form, line 226, in update
  Module plone.z3cform.patch, line 21, in BaseForm_update
  Module z3c.form.form, line 154, in update
  Module z3c.form.form, line 136, in updateWidgets
  Module z3c.form.field, line 257, in update
  Module zope.component._api, line 107, in getMultiAdapter
  Module zope.component._api, line 120, in queryMultiAdapter
  Module zope.component.registry, line 238, in queryMultiAdapter
  Module zope.interface.adapter, line 532, in queryMultiAdapter
  Module z3c.form.browser.select, line 134, in CollectionSelectFieldWidget
  Module zope.component._api, line 109, in getMultiAdapter
ComponentLookupError: ((<plone.registry.field.Set object at 0x7fd44831e5f0>, None, <HTTPRequest, URL=http://nonprofits.givesomethingback.com/portal_registry/edit/collective.lazysizes.interfaces.ILazySizesSettings.css_class_blacklist>), <InterfaceClass z3c.form.interfaces.IFieldWidget>, u'')
hvelarde commented 7 years ago

why are you editing that field there? there is a configlet for human beings ;-)

fulv commented 7 years ago

Because I get an Unauthorized error when I try to save that configlet. There are a few other bugs like that, but I don't have time right now to report them, so I uninstalled.

On Thu, Mar 9, 2017 at 3:40 PM Héctor Velarde notifications@github.com wrote:

why are you editing that filed there? there is a configlet for human beings ;-)

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/collective/collective.lazysizes/issues/30#issuecomment-285507087, or mute the thread https://github.com/notifications/unsubscribe-auth/AAcHxiixpTs0jJjefOZpacfkjif2s4GYks5rkH_3gaJpZM4MYsa0 .

hvelarde commented 7 years ago

well this indeed is not the right bug to report because is not an issue in this package; tomorrow I'll test the configlet.

hvelarde commented 7 years ago

FYI, I just tested in Plone 5.1a2 and is working like expected; IIRC that configlet is supposed to be accessed by Manager and Site Administrators.

selection_018

I can't fix a bug if you don't report it.