Hi,

I just want to report that I was able to successfully import my bugs
from Bugzilla 2.23.3 to trac 0.10.3 after making a small change to the
latest version of bugzilla2trac.py (see attached patch). Maybe you want
to apply this patch to the bugzilla2trac script.

I use the test 'BZ_VERSION >= 2233' in the patch as it works for me with
that version. However, most likely the change in the Bugzilla DB was in
an earlier version and this number can be reduced in order to work with
earlier verions, too.

Thanks,
Marco


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac 
Users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/trac-users?hl=en
-~----------~----~----~----~------~----~------~--~---

--- bugzilla2trac.py.old	2008-02-11 12:22:57.000000000 +0100
+++ bugzilla2trac.py	2008-04-15 17:56:19.000000000 +0200
@@ -28,12 +28,12 @@
 # Bugzilla version.  You can find this in Bugzilla's globals.pl file.
 #
 # Currently, the following bugzilla versions are known to work:
-#   2.11 (2110), 2.16.5 (2165), 2.18.3 (2183), 2.19.1 (2191)
+#   2.11 (2110), 2.16.5 (2165), 2.18.3 (2183), 2.19.1 (2191), 2.23.3 (2233)
 #
 # If you run this script on a version not listed here and it is successful,
 # please report it to the Trac mailing list and drop a note to
 # [EMAIL PROTECTED] so we can update the list.
-BZ_VERSION = 2180
+BZ_VERSION = 2233
 
 # MySQL connection parameters for the Bugzilla database.  These can also
 # be specified on the command line.
@@ -427,8 +427,12 @@
 
     def getFieldName(self, cursor, fieldid):
         if fieldid not in self.fieldNameCache:
-            cursor.execute("SELECT * FROM fielddefs WHERE fieldid = %s",
-                           (fieldid))
+            if BZ_VERSION >= 2233:
+                cursor.execute("SELECT * FROM fielddefs WHERE id = %s",
+                               (fieldid))
+            else:
+                cursor.execute("SELECT * FROM fielddefs WHERE fieldid = %s",
+                               (fieldid))
             fieldName = cursor.fetchall()
 
             if fieldName:

Reply via email to