@@ -20,7 +20,8 @@ Migrating from 0.7.1 to 0.8.0
2020---------------------
2121
2222Backends 'bsddb' and 'bsddb3' are removed. If you are using one of these,
23- please migrate to another backend before upgrade.
23+ you *must* migrate to another backend before upgrading.
24+
2425
25260.8.0 API changes
2627-----------------
@@ -34,6 +35,53 @@ Class.get() instead.
3435
3536XXX describe any mandatory changes to tracker layout
3637
38+ The ``config.py`` file has been replaced by ``config.ini``. You may copy
39+ the example config.ini from the classic tracker template::
40+
41+ templates/classic/config.ini
42+
43+ and modify the values therein based on the contents of your old config.py.
44+ In most cases, the names of the config variables are the same.
45+
46+ The ``select_db.py`` file has been replaced by a file in the ``db``
47+ directory called ``backend_name``. As you might guess, this file contains
48+ just the name of the backend. To figure what the contents of yours should
49+ be, use the following table:
50+
51+ ================================ =========================
52+ ``select_db.py`` contents ``backend_name`` contents
53+ ================================ =========================
54+ from back_anydbm import ... anydbm
55+ from back_metakit import ... metakit
56+ from back_sqlite import ... sqlite
57+ from back_mysql import ... mysql
58+ from back_postgresql import ... postgresql
59+ ================================ =========================
60+
61+ The ``dbinit.py`` file has been split into two new files,
62+ ``initial_data.py`` and ``schema.py``. The contents of this file are:
63+
64+ ``initial_data.py``
65+ You don't need on of these as your tracker is already initialised.
66+
67+ ``schema.py``
68+ The contents of the ``def open(name=None):`` function go in this file.
69+
70+ Copy the lines of that function (down to the next ``def`` statement) from
71+ the ``dbinit.py`` file and *remove* the leading four spaces on each line
72+ (if there's 8 leading spaces, only remove 4).
73+
74+ Remove the first few lines - those starting with ``from roundup.hyperdb
75+ import ...`` and the ``db = Database(config, name)`` line.
76+
77+ Remove the last few lines starting with ``import detectors`` down to
78+ ``return db`` inclusive.
79+
80+ Note that there's a new way to write extension code for Roundup - the old
81+ ``interfaces.py`` file will be ignored in future versions of Roundup. See
82+ the `what's new in 0.8`__ documentation for more information.
83+
84+ __ whatsnew-0.8.html
3785
38860.8.0 8-bit character set support
3987---------------------------------
@@ -47,20 +95,18 @@ characters in form fields). This version allows to change
4795the character set for http transfers. To do so, you may add
4896the following code to your ``page.html`` template::
4997
50- <div tal:define="uri string:${request/base}${request/env/PATH_INFO}"
51- tal:omit-tag="python:1"
52- >
98+ <tal:block define="uri string:${request/base}${request/env/PATH_INFO}">
5399 <a tal:attributes="href python:request.indexargs_href(uri,
54100 {'@charset':'utf-8'})">utf-8</a>
55101 <a tal:attributes="href python:request.indexargs_href(uri,
56102 {'@charset':'koi8-r'})">koi8-r</a>
57- </div >
103+ </tal:block >
58104
59105(substitute ``koi8-r`` with appropriate charset for your language).
60106Charset preference is kept in the browser cookie ``roundup_charset``.
61107
62108Lines ``meta http-equiv`` added to the tracker templates in version 0.6.0
63- are misleading and should be changed to include actual character set name::
109+ should be changed to include actual character set name::
64110
65111 <meta http-equiv="Content-Type"
66112 tal:attributes="content string:text/html;; charset=${request/client/charset}"
0 commit comments