[Setup] Unauthorized error after upgrade Plone 2.0.3 to 2.1.2

Dr.Ammon at krankenhaus-kempen.de Dr.Ammon at krankenhaus-kempen.de
Wed Feb 8 17:45:44 UTC 2006





Hello you plone-savvys,

after upgrading a Plone-2.0.3 site to 2.1.2 I got the following error
message:

...
  Module Products.PageTemplates.TALES, line 221, in evaluate
   - URL: /Hospitalnetz/folder_listing
   - Line 44, Column 16
   - Expression: <PythonExpr obj.portal_type not in ['Link', 'Image']>
   - Names:
      {'container': <PloneSite at /Hospitalnetz>,
       'context': <ATFolder at /Hospitalnetz/verwaltung>,
       'default': <Products.PageTemplates.TALES.Default instance at
0x40c66fcc>,
       'here': <ATFolder at /Hospitalnetz/verwaltung>,
       'loop': <Products.PageTemplates.TALES.SafeMapping object at
0xde8e64c>,
       'modules':
<Products.PageTemplates.ZRPythonExpr._SecureModuleImporter instance at
0x40c77eec>,
       'nothing': None,
       'options': {'args': ()},
       'repeat': <Products.PageTemplates.TALES.SafeMapping object at
0xde8e64c>,
       'request': <HTTPRequest,
URL=http://194.1.17.220:8280/Hospitalnetz/verwaltung/folder_listing>,
       'root': <Application at >,
       'template': <ZopePageTemplate at /Hospitalnetz/folder_listing used
for /Hospitalnetz/verwaltung>,
       'traverse_subpath': [],
       'user': superuser}
  Module Products.PageTemplates.ZRPythonExpr, line 47, in __call__
   - __traceback_info__: obj.portal_type not in ['Link', 'Image']
  Module Python expression "obj.portal_type not in ['Link', 'Image']", line
1, in <expression>
Unauthorized: You are not allowed to access 'portal_type' in this context

The offending part of the page template was like this:

<tal:entry tal:repeat="obj
python:here.getFolderListingFolderContents(suppressHiddenFiles=1)">
...
<a href="#" tal:condition="python: obj.portal_type not in ['Link',
'Image']"
            tal:attributes="href url"
            tal:content="obj/title_or_id" />

Any ideas? I just haven't got a clue.

Thank you for your help,

Johannes




More information about the Setup mailing list