From: richard Date: Tue, 26 Aug 2003 00:06:56 +0000 (+0000) Subject: Importing wasn't setting None values explicitly when it should have been X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=7826d9609b28c86cdc7c673676a8e88f0dbc03fc;p=roundup.git Importing wasn't setting None values explicitly when it should have been git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@1820 57a73879-2fb5-44c3-a270-3262357dd7e2 --- diff --git a/CHANGES.txt b/CHANGES.txt index 2c86ddc..47ddc91 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -2,7 +2,9 @@ This file contains the changes to the Roundup system over time. The entries are given with the most recent entry first. 2003-08-?? 0.6.1 +Fixed: - Add note about installing cgi-bin with a different interpreter +- Importing wasn't setting None values explicitly when it should have been 2003-08-08 0.6.0 diff --git a/roundup/admin.py b/roundup/admin.py index e93bf4f..06fac78 100644 --- a/roundup/admin.py +++ b/roundup/admin.py @@ -16,7 +16,7 @@ # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. # -# $Id: admin.py,v 1.55 2003-06-23 08:05:30 neaj Exp $ +# $Id: admin.py,v 1.56 2003-08-26 00:06:55 richard Exp $ '''Administration commands for maintaining Roundup trackers. ''' @@ -1144,16 +1144,6 @@ Command help: p = csv.parser(field_sep=':') file_props = p.parse(f.readline()) -# XXX we don't _really_ need to do this... -# properties = cl.getprops() -# propnames = properties.keys() -# propnames.sort() -# m = file_props[:] -# m.sort() -# if m != propnames: -# raise UsageError, _('Import file doesn\'t define the same ' -# 'properties as "%(arg0)s".')%{'arg0': args[0]} - # loop through the file and create a node for each entry maxid = 1 while 1: diff --git a/roundup/backends/back_anydbm.py b/roundup/backends/back_anydbm.py index 62d8fb6..e0f516c 100644 --- a/roundup/backends/back_anydbm.py +++ b/roundup/backends/back_anydbm.py @@ -15,7 +15,7 @@ # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. # -#$Id: back_anydbm.py,v 1.122 2003-08-12 01:49:30 richard Exp $ +#$Id: back_anydbm.py,v 1.123 2003-08-26 00:06:55 richard Exp $ ''' This module defines a backend that saves the hyperdatabase in a database chosen by anydbm. It is guaranteed to always be available in python @@ -963,7 +963,7 @@ class Class(hyperdb.Class): d[self.db.RETIRED_FLAG] = 1 continue elif value is None: - # don't set Nones + d[propname] = None continue prop = properties[propname] diff --git a/roundup/backends/back_metakit.py b/roundup/backends/back_metakit.py index 3482867..60997df 100755 --- a/roundup/backends/back_metakit.py +++ b/roundup/backends/back_metakit.py @@ -1,4 +1,4 @@ -# $Id: back_metakit.py,v 1.47 2003-05-09 01:47:50 richard Exp $ +# $Id: back_metakit.py,v 1.48 2003-08-26 00:06:56 richard Exp $ ''' Metakit backend for Roundup, originally by Gordon McMillan. @@ -1209,6 +1209,9 @@ class Class: if int(value): d['_isdel'] = 1 continue + elif value is None: + d[propname] = None + continue prop = properties[propname] if isinstance(prop, hyperdb.Date): diff --git a/roundup/backends/rdbms_common.py b/roundup/backends/rdbms_common.py index a6e268d..2bbe0e0 100644 --- a/roundup/backends/rdbms_common.py +++ b/roundup/backends/rdbms_common.py @@ -1,4 +1,4 @@ -# $Id: rdbms_common.py,v 1.58 2003-08-12 02:18:46 richard Exp $ +# $Id: rdbms_common.py,v 1.59 2003-08-26 00:06:56 richard Exp $ ''' Relational database (SQL) backend common code. Basics: @@ -1123,6 +1123,9 @@ class Class(hyperdb.Class): if int(value): retire = 1 continue + elif value is None: + d[propname] = None + continue prop = properties[propname] if value is None: