Skip to content. | Skip to navigation

Personal tools


You are here: Home / Blog / Dogfood Dinner Bell

Dogfood Dinner Bell

by admin last modified Apr 02, 2010 06:02 AM
It's that time again to upgrade my Blog to the latest Plone.

With the first Plone 4 Beta out it's time to eat my own dogfood and upgrade my blog. This site is now running on Plone 4.0b1-1. So come poke around if you like and tell me what's broken. :)

The upgrade went pretty smoothly for my main site. I had some other, older, Plone portals where I've installed various add-ons in the past and for those I had to do some manual cleanup of some broken objects.

The unified folder implementation makes removing broken objects very difficult. The manage_delObjects(), _delObject, and _delOb methods are all broken before the folders have been migrated but the migration won't complete if there are broken objects in the folder. I had to do something like this where "idx" is the index in _objects of the broken object and 'foo' is the id:

>>> folder._objects = folder._objects[:idx]+folder._objects[idx+1:]
>>> delattr(folder, 'foo')
>>> import transaction
>>> transaction.commit()

On two of my portals I also had some regular TextIndex'es in the catalog, which I guess are no longer around. Those I was able to just delete in the "Indexes" tab of the ZMI for portal_catalog. Since these were core indexes like "Title" I used portal_setup to install just the catalog import step from the Plone base profile. Being a base profile this means running the import step cleared the indexes so I also had to update those catalogs.

After all that was done I just uninstalled the classic theme and Kupu and then installed and configured Everything seems to be working well.

Just to polish things off, I wanted to make sure I was getting the full benefit of Hanno's ExtensionClass/ZODB fix. The one thing I can't find is a clear migration procedure. As far as I understand the ZODB, the objects created before the fix would need to be written to the ZODB again to see the benefit from the fix. So I used the following at a "bin/instance debug" prompt:

>>> app.ZopeFindAndApply(app, search_sub=1, apply_func=lambda obj, path: setattr(obj, '_p_changed', True))
>>> import transaction
>>> transaction.commit()

That should do it, but if anyone knows how that's insufficient or knows a better way to accomplish the migration, please do leave a comment.

OpenID Login


IRC: rossp
Yahoo IM: patterson_ross
AIM: rosspatters
Skype: merpattersonnet

PO Box 7775 #10587
San Francisco, CA

+1 (415) 894-5323