Wednesday, April 30, 2008

moinmoin upgrade to 1.6 from 1.5

A few notes on the upgrade for future reference.

I upgraded our wiki to moin 1.6.3 from 1.5.8

I backed up the old wiki

I installed moin via python setup.py

I followed the instructions to run the migration scipts as described in docs/README.migrationI updated the line in wikiconfig.py Old: from MoinMoin.multiconfig import DefaultConfig to New: from MoinMoin.config.multiconfig import DefaultConfig as instructed when I ran the test server.

Next I updated mentalwealth.py for the MentalWealth theme (default on our system). Just one change in the Page.split_title function. It doesn't take the redundant request argument in 1.6
Basically, change
< Page(self.request, action).split_title(self.request, force=1)
--> Page(self.request, action).split_title(force=1)

diff -B -b old/mentalwealth.py mentalwealth.py
75c75
< label = Page(self.request, action).split_title(self.request, force=1) to label = Page(self.request, action).split_title(force=1)
75c75
< label = Page(self.request, action).split_title(self.request, force=\
1)
---
> label = Page(self.request, action).split_title(force=1)


Next I copied over the new underlay to replace the old one because of a change in [GetText(xx)] to <> formating. That is, I did a cp --reply=yes -r moin-1.6.3/wiki/underlay/* mywiki/underlay

It now seems to work under 1.6.3 and the mentalwealth theme.

I then could go ahead and add http authentication to my wikiconfig.py
(python code)
user_autocreate = True
from MoinMoin.auth.http import http
from MoinMoin.auth import moin_login, moin_session
auth = [http, moin_login, moin_session] # add moin_login ??