2.1 to 2.2 upgrade problem

steve-p

Joined: 2007-04-26
Posts: 8
Posted: Thu, 2007-04-26 15:44

I've just upgraded my gallery and everything seems fine, except for the maintenance option in the site admin section. It has this at the top:

Quote:
Error: building $result[0]: " . $ret->getAsHtml(); } if ($error) { $this->_printFailure($debug . $error, ++$broken, $module); } if (++$i % 5 == 0 || $i == $total) { $ret = $this->_updateProgress($module, $i, $total); if ($ret) { return array($ret, null, null); } } } $result = array($module->translate(array('text' => 'Checked %d items', 'arg1' => $total))); if ($built) { $result[] = $module->translate(array('text' => '%d items built', 'arg1' => $built)); } if ($broken) { $result[] = $module->translate(array('text' => '%d items failed', 'arg1' => $broken)); } return array(null, true, $result); } function _rescan(&$item) { list ($ret, $lockId) = GalleryCoreApi::acquireWriteLock($item->getId()); if ($ret) { return $ret; } list ($ret, $item) = $item->refresh(); if ($ret) { GalleryCoreApi::releaseLocks($lockId); return $ret; } $ret = $item->rescan(); if ($ret) { GalleryCoreApi::releaseLocks($lockId); return $ret; } $ret = $item->save(); if ($ret) { GalleryCoreApi::releaseLocks($lockId); return $ret; } $ret = GalleryCoreApi::releaseLocks($lockId); if ($ret) { return $ret; } return null; } function _updateProgress(&$module, $i, $total) { global $gallery; $storage =& $gallery->getStorage(); $templateAdapter =& $gallery->getTemplateAdapter(); $message = $module->translate( array('text' => 'Processing image %d of %d', 'arg1' => $i, 'arg2' => $total)); $templateAdapter->updateProgressBar($message, '', $i / $total); /* Release locks (avoid too many open files for flock based locking) */ $ret = $storage->checkPoint(); if ($ret) { return $ret; } $gallery->guaranteeTimeLimit(120); return null; } function _printFailure($message, $count, &$module) { if ($count == 1) { print '
' . $module->translate('Debug output for failed items:') . '
'; } print '

' . $message . '

'; } /** * @see MaintenanceTask::requiresProgressBar */ function requiresProgressBar() { return true; } } ?>

The formatting of the page (which renders underneath) is also a bit wrong. Any pointers would be appreciated :)

 
steve-p

Joined: 2007-04-26
Posts: 8
Posted: Sat, 2007-04-28 08:19

I take it that no-one else has encountered this at all then. Steps I have taken to try to track down the problem include:

  • Re-ran the verification step of the upgrade to double check that all files were in place and not reported to be missing or modified
  • Removed files that were left over from previous version
  • Switched to a different skin in case it was related to that - made no difference
  • Enabled debug mode - nothing looking like an error message was reported

I've run out of ideas now and it's stopping me running the maintenance tasks such as optimising the database etc.

 
steve-p

Joined: 2007-04-26
Posts: 8
Posted: Sat, 2007-04-28 11:05

This is the output from the system information tool in case it rings any bells:

Quote:
Gallery version = 2.1.2 core 1.1.0.2
PHP version = 4.4.4 cgi
Webserver = Apache/1.3.37 (Unix)
Database = mysqlt 5.0.24-standard-log, lock.system=database
Toolkits = ArchiveUpload, Exif, Gd
Acceleration = none, none
Operating system = Linux infong 2.4 #1 SMP Thu Jan 13 08:59:31 CET 2005 i686 unknown
Default theme = matrix
Locale = en_US
Browser = Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.7) Gecko/20060909 Firefox/1.5.0.7

 
jaa1180

Joined: 2005-02-11
Posts: 48
Posted: Thu, 2007-05-03 18:45

I have encountered a problem but not that specific problem.
Have you all ready did the cache clean and everything?
Tried replacing any files?
============================
-Jeff
www.avvedutiphotography.com
"Capturing God's creation for His glory."
<><

 
steve-p

Joined: 2007-04-26
Posts: 8
Posted: Fri, 2007-05-04 08:08

I used the support page cache maintenance to delete all caches. I also copied the files up again and it made no difference.

 
valiant

Joined: 2003-01-04
Posts: 32509
Posted: Fri, 2007-05-04 14:03

that's the 2nd time i read about this issue.

from the code, it looks like the modules/core/classes/BuildDerivativesTask.class.

please delete that file and reupload it.
maybe get the modules/core/classes/BuildDerivativesTask.class file from another gallery2.zip archive...

--------------
Documentation: Support / Troubleshooting | Installation, Upgrade, Configuration and Usage

 
steve-p

Joined: 2007-04-26
Posts: 8
Posted: Tue, 2007-05-08 10:42
valiant wrote:
that's the 2nd time i read about this issue.

from the code, it looks like the modules/core/classes/BuildDerivativesTask.class.

please delete that file and reupload it.
maybe get the modules/core/classes/BuildDerivativesTask.class file from another gallery2.zip archive...

Many thanks - I copied modules/core/classes/BuildDerivativesTask.class up again from the original zip archive, and this time it has worked. What's strange is that looking at the timestamp, the second time I uploaded all files to try to fix the problem, this particular file didn't get updated for some reason. Also, when I uploaded it again just now, it was exactly the same size, so somehow it must have got corrupted. Anyway it's working now, thanks again.