[geeklog-devel] Upgrade bug in 1.8.0

Dirk Haun dirk at haun-online.de
Sat May 28 08:03:43 EDT 2011


Trying to reproduce someone's upgrade problems, I found an unrelated upgrade problem in 1.8.0:

When you're upgrading from a pre-1.5.0 version, the plugin upgrades (e.g. for the Calendar) fail when trying to initialize the Configuration:

Fatal error: 1054: Unknown column 'tab' in 'field list' in /geeklog/system/databases/mysql.class.php on line 260

Call Stack
#   Time    Memory  Function    Location
1   0.0115  591372  {main}( )   ../migrate.php:0
2   0.1030  1373756 INST_doDatabaseUpgrades( )  ../migrate.php:784
3   3.6755  2265908 upgrade_CalendarPlugin( )   ../lib-upgrade.php:408
4   3.6771  2303464 plugin_initconfig_calendar( )   ../mysql_1.4.1_to_1.5.0.php:482
5   3.6774  2305140 config->add( )  ../install_defaults.php:147
6   3.6776  2306568 config->_DB_escapedQuery( ) ../config.class.php:523
7   3.6776  2306568 DB_query( ) ../config.class.php:1752
8   3.6776  2306624 database->dbQuery( )    ../lib-database.php:208
9   3.6782  2306788 trigger_error ( )   ../mysql.class.php:260

The problem is with the "tab" column, which is new in 1.8.0. At the point of the failure, the database is at 1.5.0, i.e. it does have a conf_values table but without the "tab" column. Yet plugin_initconfig_calendar calls the Configuration's add() function with a valid value for $tab, so we try to write it to the db. Oops.

I haven't had a good idea yet how to get around this. Anyone?

bye, Dirk




More information about the geeklog-devel mailing list