Plone.resourceregistries.scripts error

I upgraded a site from 5.0.x to 5.1b3 and it gives me the following error:

error while rendering plone.resourceregistries.scripts error while rendering plone.resourceregistries.styles

Is there a workaround here ( I did try to rerun a lot of /portal_setup profiles )

ooops, forgot this:

2017-04-19 20:32:52 ERROR Error while rendering viewlet-manager=plone.htmlhead.links, viewlet=plone.resourceregistries.styles
Traceback (most recent call last):
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/", line 112, in render
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/", line 59, in render
    return self.index()
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/Zope2-2.13.26-py2.7.egg/Products/Five/browser/", line 125, in __call__
    return self.im_func(im_self, *args, **kw)
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/Zope2-2.13.26-py2.7.egg/Products/Five/browser/", line 59, in __call__
    sourceAnnotations=getattr(debug_flags, 'sourceAnnotations', 0),
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/zope.pagetemplate-3.6.3-py2.7.egg/zope/pagetemplate/", line 132, in pt_render
    strictinsert=0, sourceAnnotations=sourceAnnotations
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/", line 98, in __call__
    return self.template.render(**kwargs)
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/", line 163, in render
    return base_renderer(**context)
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/Chameleon-2.25-py2.7.egg/chameleon/zpt/", line 261, in render
    return super(PageTemplate, self).render(**vars)
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/Chameleon-2.25-py2.7.egg/chameleon/", line 191, in render
    raise_with_traceback(exc, tb)
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/Chameleon-2.25-py2.7.egg/chameleon/", line 171, in render
    self._render(stream, econtext, rcontext)
  File "", line 88, in render
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/", line 161, in __call__
    return base()
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/Products.CMFPlone-5.1b3-py2.7.egg/Products/CMFPlone/resources/browser/", line 90, in styles
    result = self.ordered_bundles_result()
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/Products.CMFPlone-5.1b3-py2.7.egg/Products/CMFPlone/resources/browser/", line 232, in ordered_bundles_result
    self.get_data(bundle, result)
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/Products.CMFPlone-5.1b3-py2.7.egg/Products/CMFPlone/resources/browser/", line 55, in get_data
    if not bundle.last_compilation\
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/Products.CMFPlone-5.1b3-py2.7.egg/Products/CMFPlone/resources/", line 79, in last_compilation
    loc, path = self._real_path(ctx)
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/Products.CMFPlone-5.1b3-py2.7.egg/Products/CMFPlone/resources/", line 36, in _real_path
    resource = getSite().restrictedTraverse(resource_path)
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/Zope2-2.13.26-py2.7.egg/OFS/", line 317, in restrictedTraverse
    return self.unrestrictedTraverse(path, default, restricted=True)
  File "/home/medialog/plone5/ektedata8084/buildout-cache/eggs/Zope2-2.13.26-py2.7.egg/OFS/", line 300, in unrestrictedTraverse
    raise e
KeyError: 'styles.css'

 - Expression: "view/styles"
 - Filename:   ... -py2.7.egg/Products/CMFPlone/resources/browser/
 - Location:   (line 1: col 26)
 - Source:     <tal:styles repeat="style view/styles"

@zopyx I noticed you have this error too (on the XML director demo site)


turns out


is missing..

Are you saying this is a bug? If so, could you please file the issue?

It is a bug in the pp.client add-on

(if it is a bug that an add on can break a site like that is another question (?) )

I'm having the dreaded resource registries issue now!
It isn't related to pp.client since I don't have pp.client.

error while rendering plone.resourceregistries.scripts error while rendering plone.resourceregistries.styles

I know this is a long time ago but @espenmn how did you trace the issue?

Took a look at my logs and I'm seeing this keyerror:

KeyError: 'collective.js.jqueryui.custom.min.js'

I think this might be the culprit.

It turns out that the collective.js.jqueryui package provides the "machinery" related to the collective.js.jqueryui.custom.min.js key. I had to add collective.js.jqueryui as a dependency and rerun buildout.

Hopefully I can totally remove collective.js.jqueryui as a dependency shortly.

There was an entry in a ZCML file for a stylesheet that did not exist.

So I just added an empty styles.css in the add-on.

In your case, I would install one and one add on and see if you get an error. If you do: check if all the files for the entries exist (in registry.xml of that add on).

UPDATE: I see you found the answer.

1 Like