changeset 3166:3204488d20b5

hack to fix some anydbm export problems [SF#1081454]
author Richard Jones <richard@users.sourceforge.net>
date Mon, 14 Feb 2005 05:39:37 +0000
parents 24476db8872f
children d8d1ebd80930
files CHANGES.txt doc/index.txt roundup/backends/back_anydbm.py
diffstat 3 files changed, 6 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/CHANGES.txt	Mon Feb 14 04:53:41 2005 +0000
+++ b/CHANGES.txt	Mon Feb 14 05:39:37 2005 +0000
@@ -96,6 +96,7 @@
 - fix search_checkboxes macro (sf patch 1113828)
 - fix bug in date editing in Metakit
 - allow suppression of search_text in indexargs_form (sf bug 1101548)
+- hack to fix some anydbm export problems (sf bug 1081454)
 
 
 2005-01-06 0.7.11
--- a/doc/index.txt	Mon Feb 14 04:53:41 2005 +0000
+++ b/doc/index.txt	Mon Feb 14 05:39:37 2005 +0000
@@ -90,6 +90,7 @@
 Gus Gollings,
 Dan Grassi,
 Robin Green,
+Charles Groves,
 Engelbert Gruber,
 Bruce Guenter,
 Juergen Hermann,
--- a/roundup/backends/back_anydbm.py	Mon Feb 14 04:53:41 2005 +0000
+++ b/roundup/backends/back_anydbm.py	Mon Feb 14 05:39:37 2005 +0000
@@ -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.184 2005-02-14 02:48:11 richard Exp $
+#$Id: back_anydbm.py,v 1.185 2005-02-14 05:39:37 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
 versions >2.1.1 (the dumbdbm fallback in 2.1.1 and earlier has several
@@ -2025,7 +2025,9 @@
                             # don't export empties
                             continue
                         elif isinstance(prop, hyperdb.Date):
-                            value = value.get_tuple()
+                            # this is a hack - some dates are stored as strings
+                            if not isinstance(value, type('')):
+                                value = value.get_tuple()
                         elif isinstance(prop, hyperdb.Interval):
                             value = value.get_tuple()
                         elif isinstance(prop, hyperdb.Password):

Roundup Issue Tracker: http://roundup-tracker.org/