Loading...
 
Skip to main content

Image galleries to file galleries migration script fails

Status
Closed
Subject
Image galleries to file galleries migration script fails
Version
21.x
Category
  • Bug
Feature
Image Gallery
Resolution status
Fixed or Solved
Submitted by
Jean-Marc Libs
Volunteered to solve
Jean-Marc Libs
Lastmod by
Jean-Marc Libs
Rating
(0)
Description

On a site with image galleries, there is a button in page tiki-galleries.php which claims Migrate Images to File Gallery

When I click on it, a new File gallery is created and named Migrated Image Galleries (that is perfect!)
For each image gallery, a file gallery with the same name as the image gallery is created as a child of Migrated Image Galleries (still perfect!)

But no images are actually migrated to these new file galleries. The new file galleries are empty and the old image galleries are still there.

Using the command line version gives the same lack of result:

Copy to clipboard
php console.php gallery:migrate All files migrated! feedback: L'image a été réduite : %s x %s -> %s x %s error: Duplicate file found as `Nouveau Fichier`. Upload rejected. error: Duplicate file found as `Beatrice1.jpeg`. Upload rejected. error: Duplicate file found as `kitty.jpg`. Upload rejected. error: Duplicate file found as `160x55_INESSStccn.jpg`. Upload rejected.

But nothing was actually migrated.

Files are stored on the file system, in case that makes a difference.

This prevents people from getting rid of deprecated image galleries feature.

See issue reproduced on: http://jyhem-9952-7324.show2.tikiwiki.org/


This also creates the file galeries without migrating the files:

Copy to clipboard
root@seed22:/var/www/jyhem-9952-7324# php console.php gallery:migrate Undefined index: show_filename on line 175 of /var/www/jyhem-9952-7324/lib/filegals/filegallib.php Undefined index: show_filename on line 177 of /var/www/jyhem-9952-7324/lib/filegals/filegallib.php Undefined offset: 31 on line 737 of /var/www/jyhem-9952-7324/lib/metadata/datatypes/exif.php Undefined index: show_filename on line 175 of /var/www/jyhem-9952-7324/lib/filegals/filegallib.php Undefined index: show_filename on line 177 of /var/www/jyhem-9952-7324/lib/filegals/filegallib.php Undefined index: show_filename on line 175 of /var/www/jyhem-9952-7324/lib/filegals/filegallib.php Undefined index: show_filename on line 177 of /var/www/jyhem-9952-7324/lib/filegals/filegallib.php Undefined offset: 31 on line 737 of /var/www/jyhem-9952-7324/lib/metadata/datatypes/exif.php All files migrated!
Solution

That was an issue in lib/core/Tiki/FileGallery/SaveHandler.php
Fixed in 25f639a..844ebf4

Importance
5
Easy to solve?
6
Priority
30
Demonstrate Bug on Tiki 19+
Demonstrate Bug (older Tiki versions)
Ticket ID
7324
Created
Wednesday 18 March, 2020 17:16:37 UTC
by Jean-Marc Libs
LastModif
Wednesday 25 March, 2020 22:23:00 UTC


Show PHP error messages