Code

. Alternate email addresses are now available for users. See the MIGRATION
[roundup.git] / MIGRATION.txt
1 Migrating to newer versions of Roundup
2 ======================================
4 Please read each section carefully and edit your instance home files
5 accordingly.
7 This file contains information for users upgrading from:
8   0.4.0 -> 0.4.1
9   0.3.x -> 0.4.x
10   0.2.x -> 0.3.x
13 Migrating from 0.4.0 to 0.4.1
14 =============================
16 Configuration
17 -------------
19 To allow more fine-grained access control, the variable used to check
20 permission to auto-register users in the mail gateway is now called
21 ANONYMOUS_REGISTER_MAIL rather than overloading ANONYMOUS_REGISTER. If the
22 variable doesn't exist, then ANONYMOUS_REGISTER is tested as before.
25 Alternate E-Mail Addresses
26 --------------------------
28 If you add the property "alternate_addresses" to your user class, your users
29 will be able to register alternate email addresses that they may use to
30 communicate with roundup as. All email from roundup will continue to be sent
31 to their primary address.
33 If you have not edited the dbinit.py file in your instance home directory,
34 you may simply copy the new dbinit.py file from the core code. If you used
35 the classic schema, the interfaces file is in:
37  <roundup source>/roundup/templates/classic/dbinit.py
39 If you used the extended schema, the file is in:
41  <roundup source>/roundup/templates/extended/dbinit.py 
43 If you have modified your dbinit.py file, you need to edit the dbinit.py
44 file in your instance home directory. Find the lines which define the user
45 class:
47     user = Class(db, "msg",
48                     username=String(),   password=Password(),
49                     address=String(),    realname=String(), 
50                     phone=String(),      organisation=String(),
51                     alternate_addresses=String())
53 You will also want to add the property to the user's details page. The
54 template for this is the "user.item" file in your instance home "html"
55 directory. Similar to above, you may copy the file from the roundup source if
56 you haven't modified it. Otherwise, add the following to the template:
58    <display call="multiline('alternate_addresses')">
60 with appropriate labelling etc. See the standard template for an idea.
64 Migrating from 0.3.x to 0.4.x
65 =============================
67 Message-ID and In-Reply-To addition
68 -----------------------------------
69 0.4.0 adds the tracking of messages by message-id and allows threading
70 using in-reply-to. Most e-mail clients support threading using this
71 feature, and we hope to add support for it to the web gateway. If you
72 have not edited the dbinit.py file in your instance home directory, you may
73 simply copy the new dbinit.py file from the core code. If you used the
74 classic schema, the interfaces file is in:
76  <roundup source>/roundup/templates/classic/dbinit.py
78 If you used the extended schema, the file is in:
80  <roundup source>/roundup/templates/extended/dbinit.py 
82 If you have modified your dbinit.py file, you need to edit the dbinit.py
83 file in your instance home directory. Find the lines which define the msg
84 class:
86     msg = FileClass(db, "msg",
87                     author=Link("user"), recipients=Multilink("user"),
88                     date=Date(),         summary=String(),
89                     files=Multilink("file"))
91  and add the messageid and inreplyto properties like so:
93     msg = FileClass(db, "msg",
94                     author=Link("user"), recipients=Multilink("user"),
95                     date=Date(),         summary=String(),
96                     files=Multilink("file"),
97                     messageid=String(),  inreplyto=String())
99 Also, configuration is being cleaned up. This means that your dbinit.py will
100 also need to be changed in the open function. If you haven't changed your
101 dbinit.py, the above copy will be enough. If you have, you'll need to change
102 the line (round line 50):
104     db = Database(instance_config.DATABASE, name)
106 to:
108     db = Database(instance_config, name)
111 Configuration
112 -------------
113 INSTANCE_NAME and EMAIL_SIGNATURE_POSITION have been added to the
114 instance_config.py. The simplest solution is to copy the default values
115 from template in the core source.
117 The mail gateway now checks ANONYMOUS_REGISTER to see if unknown users are to
118 be automatically registered with the tracker. If it is set to "deny" then
119 unknown users will not have access. If it is set to "allow" they will be
120 automatically registered with the tracker.
123 CGI script roundup.cgi
124 ----------------------
125 The CGI script has been updated with some features and a bugfix, so you should
126 copy it from the roundup cgi-bin source directory again. Make sure you update
127 the ROUNDUP_INSTANCE_HOMES after the copy.
130 Nosy reactor
131 ------------
132 The nosy reactor has also changed - copy the nosyreactor.py file from the core
133 source roundup/templates/[schema]/detectors/nosyreactor.py to your instance
134 home "detectors" directory.
137 HTML templating
138 ---------------
139 The field() function was incorrectly implemented - links and multilinks now
140 display as text fields when rendered using field(). To display a menu (drop-
141 down or select box) you need to use the menu() function.
145 Migrating from 0.2.x to 0.3.x
146 =============================
148 Cookie Authentication changes
149 -----------------------------
150 0.3.0 introduces cookie authentication - you will need to copy the
151 interfaces.py file from the roundup source to your instance home to enable
152 authentication. If you used the classic schema, the interfaces file is in:
154  <roundup source>/roundup/templates/classic/interfaces.py
156 If you used the extended schema, the file is in:
158  <roundup source>/roundup/templates/extended/interfaces.py
160 If you have modified your interfaces.Client class, you will need to take
161 note of the login/logout functionality provided in roundup.cgi_client.Client
162 (classic schema) or roundup.cgi_client.ExtendedClient (extended schema) and
163 modify your instance code apropriately.
166 Password encoding
167 -----------------
168 This release also introduces encoding of passwords in the database. If you
169 have not edited the dbinit.py file in your instance home directory, you may
170 simply copy the new dbinit.py file from the core code. If you used the
171 classic schema, the interfaces file is in:
173  <roundup source>/roundup/templates/classic/dbinit.py
175 If you used the extended schema, the file is in:
177  <roundup source>/roundup/templates/extended/dbinit.py
180 If you have modified your dbinit.py file, you may use encoded passwords:
182  1. Edit the dbinit.py file in your instance home directory
183  1a. At the first code line of the open() function:
185     from roundup.hyperdb import String, Date, Link, Multilink
187       alter to include Password, as so:
189     from roundup.hyperdb import String, Password, Date, Link, Multilink
191  1b. Where the password property is defined (around line 66):
193     user = Class(db, "user", 
194                     username=String(),   password=String(),
195                     address=String(),    realname=String(), 
196                     phone=String(),      organisation=String())
197     user.setkey("username")
199       alter the "password=String()" to "password=Password()":
201     user = Class(db, "user", 
202                     username=String(),   password=Password(),
203                     address=String(),    realname=String(), 
204                     phone=String(),      organisation=String())
205     user.setkey("username")
207  2. Any existing passwords in the database will remain cleartext until they
208     are edited. It is recommended that at a minimum the admin password be
209     changed immediately:
211       roundup-admin -i <instance home> set user1 password=<new password>
214 Configuration
215 -------------
216 FILTER_POSITION, ANONYMOUS_ACCESS, ANONYMOUS_REGISTER have been added to
217 the instance_config.py. Simplest solution is to copy the default values from
218 template in the core source.
220 MESSAGES_TO_AUTHOR has been added to the IssueClass in dbinit.py. Set to 'yes'
221 to send nosy messages to the author. Default behaviour is to not send nosy
222 messages to the author. You will need to add MESSAGES_TO_AUTHOR to your
223 dbinit.py in your instance home.
226 CGI script roundup.cgi
227 ----------------------
228 There have been some structural changes to the roundup.cgi script - you will
229 need to install it again from the cgi-bin directory of the source
230 distribution. Make sure you update the ROUNDUP_INSTANCE_HOMES after the
231 copy.