~ubuntu-branches/ubuntu/natty/moin/natty-updates

« back to all changes in this revision

Viewing changes to wiki/underlay/pages/HelpOnUpdatingPython/revisions/00000001

  • Committer: Bazaar Package Importer
  • Author(s): Jonas Smedegaard
  • Date: 2008-06-22 21:17:13 UTC
  • mto: This revision was merged to the branch mainline in revision 18.
  • Revision ID: james.westby@ubuntu.com-20080622211713-inlv5k4eifxckelr
ImportĀ upstreamĀ versionĀ 1.7.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
## Please edit system and help pages ONLY in the master wiki!
 
2
## For more information, please see MoinMoin:MoinDev/Translation.
 
3
##master-page:Unknown-Page
 
4
##master-date:Unknown-Date
 
5
#acl -All:write Default
 
6
#format wiki
 
7
#language en
 
8
== Updating Python ==
 
9
 
 
10
If you want to change the Python running your MoinMoin installation there are some issues to keep in mind:
 
11
 
 
12
=== Location of the MoinMoin directory ===
 
13
 
 
14
The default installation process (`setup.py`) installed the MoinMoin files into the site-packages directory of the current Python installation (for example `/usr/lib/python2.4/site-packages`). If you move to another Python interpreter you must reinstall the MoinMoin files into the new `lib/pythonX.X/site-packages` directory. If you installed the MoinMoin files elsewhere and adjusted `sys.path` this is not a problem.
 
15
 
 
16
=== The precompiled Python files (.pyc) ===
 
17
 
 
18
Python does not grant that .pyc files are compatible between Python versions. If you change the Python interpreter you should recompile the Python scripts. You may use 
 
19
 
 
20
{{{
 
21
python -c "import compileall; compileall.compile_dir('/path/to/MoinMoin')"
 
22
}}}
 
23
 
 
24
for this. If you reinstall MoinMoin for the new interpreter the step is not needed/done by setup.py.
 
25
 
 
26
=== Empty Page Cache ===
 
27
 
 
28
The page cache uses Python byte code for faster page rendering. To avoid compatibility problems you should empty the cache by hand by deleting all files in `data/pages/*/cache/` and `underlay/pages/*/cache/`.