[Setup] Re: AttributeError:batchedFolderContents when migrating

Maurits van Rees m.van.rees at zestsoftware.nl
Fri Jan 4 23:12:00 UTC 2008


Walter Landry, on 2008-01-04:
> Hello,
>
> I am trying to migrate a Plone instance currently running on Debian
> sarge (Zope 2.7.5, Plone 2.0.4) to Debian etch (Zope 2.9.6, Plone
> 2.5.1).
...
> 14) Now I get an error
>
>   Error exceptions.AttributeError on here/portlet_recent/macros/portlet: toPortalTime
>
>   This does not make sense to me, because if I look at the source for
>   portlet_recent, it is not using toPortalTime.  In any case, I can
>   get rid of this error by removing portlet_recent from the list of
>   slots.

Maybe you are looking at the wrong portlet_recent.  Search for it in
portal_skins.  Maybe it is in the custom layer.  Or an add-on product
may be overriding the default.

> With that fixed, it mostly works, but I am getting the error
> AttributeError:batchedFolderContents whenever I log into the plone
> site and look at the Contents tab.
...
>   Module Products.PageTemplates.TALES, line 221, in evaluate
>    - URL: /cig/folder_contents
>    - Line 22, Column 6
>    - Expression: <PythonExpr here.batchedFolderContents(suppressHiddenFiles=1)>
...
> AttributeError: batchedFolderContents

Perhaps folder_contents.pt has also been customized or overriden by an
add-on product so the updated 2.5 template is shadowed?

This is in the HISTORY.txt for Plone 2.1:

    - Restored batchedFolderContents for backwards compatibility, and moved
      batching into the python script getFolderContents (which takes optional
      'batch' and 'b_size' parameters).  Marked batchedFolderContents and
      getFolderListingFolderContents as deprecated, both just call
      getFolderContents now.
      [alecm]

So in 2.1 batchedFolderContents was only there for backwards
compatibility.  It has been totally removed in 2.5.

-- 
Maurits van Rees | http://maurits.vanrees.org/
            Work | http://zestsoftware.nl/
"From an eekhoorn grows an oak." [semi-Dutch proverb]




More information about the Setup mailing list