Problem with displaying content Plone 5.0.8

Hello everyone,
I have request for solving problem regarding company's Plone page, I haven't work on this site for a very long time so I am still going around this to get myself familiar with everything, maybe this error traceback will tell You more than me, so if You have any directions to point me on solving this, please do help me...
On navigation to a certain page which shows some documents we get following error:
(Other pages in same folder show contents without problems)

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 Shared.DC.Scripts.Bindings, line 322, in call
Module Shared.DC.Scripts.Bindings, line 359, in _bindAndExec
Module Products.CMFCore.FSPageTemplate, line 237, in _exec
Module Products.CMFCore.FSPageTemplate, line 177, in pt_render
Module Products.PageTemplates.PageTemplate, line 87, in pt_render
Module zope.pagetemplate.pagetemplate, line 132, in pt_render
Module, line 98, in call
Module, line 163, in render
Module chameleon.zpt.template, line 261, in render
Module chameleon.template, line 191, in render
Module chameleon.template, line 171, in render
Module, line 857, in render
Module, line 1223, in render_master
Module, line 420, in render_content
Module, line 843, in __fill_content_core
Module, line 767, in render_listing
Module, line 122, in render_content_core
Module, line 874, in render_listing
Module, line 744, in __fill_entries
Module, line 473, in render_entries
Module, line 732, in __fill_entry
Module, line 140, in render_listitem
Module chameleon.utils, line 406, in getitem
NameError: item_icon

  • Expression: "item_icon/url"
  • Filename: ... ucts\CMFPlone\skins\plone_content\
  • Location: (line 46: col 52)
  • Source: tal:condition="item_icon/url"
  • Arguments: repeat: {...} (0)
    template: <ImplicitAcquisitionWrapper folder_tabular_view at 0xa872940>
    modules: <instance - at 0x28c6828>
    here: <ImplicitAcquisitionWrapper formulare at 0xa72bfd0>
    user: <ImplicitAcquisitionWrapper - at 0x66215f8>
    nothing: <NoneType - at 0x6af1eb14>
    container: <ImplicitAcquisitionWrapper SuB at 0xae3ef80>
    default: <object - at 0xc78bd8>
    request: <instance - at 0xae3eeb8>
    wrapped_repeat: <SafeMapping - at 0xb3f25d0>
    traverse_subpath: <list - at 0xa72b440>
    loop: {...} (1)
    context: <ImplicitAcquisitionWrapper formulare at 0xa72bfd0>
    translate: <function translate at 0xae697b0>
    root: <ImplicitAcquisitionWrapper Zope at 0xae3e058>
    options: {...} (1)
    target_language: <NoneType - at 0x6af1eb14>

A NameError usually indicates a programming error.

In your case, look at line 46 of ... ucts\CMFPlone\skins\plone_content\ You should see there something like tal:condition="item_icon/url". Add | nothung before the closing ".

1 Like

This should in fact be "Add | nothing (not nothung).

Hello Mr. Maurer,
Thank You for answering,
I changed 46.line into:
tal:condition="Add | nothing"
And it worked, now content is shown as it should. Should I leave this line like this or?

As I wrote, NameError indicates a programming error. As the affected template belongs to Plone itself (i.e. it is fairly often used), there is something special in your site which "triggers" this error while it typically is masked.

You have various options:

  • report the error in Plone's bug tracker. This increases the chance that the error is fixed in future releases. Otherwise, the error may resurface when you make a Plone upgrade (but you know then how to fix it)

  • try to understand what speciality "triggered" the error and remove it. If you succeed (which is not sure), then you may live with unmodified Plone code.

  • try to upgrade to a newer Plone version. Maybe, the error is fixed there.

  • use jbot ("Just another Bunch Of Templates") (the complete package name has a prefix (maybe collective, but I forgot the details) to use a fixed template beside the buggy Plone one.

I do not know which option is the best adapted for you.

Some options can be combined: thus, you can report the bug in any case.