darktable import freezes on missing thumbnail in image
When I try to import Images from my smartphone (Android 5.0.2, PTP Mode), darktable freezes on import and needs to be killed.
The reason for that seems to be, that some Images on the device are missing an EXIF thumbnail when Importing. This Problem by itself is not darktable specific but a problem of gphoto2.
gphoto2 -T crashes (exit 1) if any photo does not provide a thumbnail; gphoto -t # works on all photos except the ones with missing thumbnails. importing the image itself through gphoto2 -P works without a problem.
While I understand, that gphoto2 can't be fixed here, i suggest that maybe darktable should be a bit more fault-tolerant in that case (i.e. getting thumbs one by one if an error occurs and handle the error of missing thumbs properly by simply not showing the thumbnail in the importer).
Output of gphoto2 in such cases (1437595816717.jpeg has no thumbnail embedded):
ezri:tmp uk$ gphoto2 -a Abilities for camera : USB PTP Class Camera Serial port support : no USB support : yes Capture choices : : Image : Preview Configuration support : yes Delete selected files on camera : yes Delete all files on camera : no File preview (thumbnail) support : yes File upload support : yes ezri:tmp uk$ gphoto2 -T -v gphoto2 2.5.5 Copyright (c) 2000-2014 Lutz Mueller and others gphoto2 comes with NO WARRANTY, to the extent permitted by law. You may redistribute copies of gphoto2 under the terms of the GNU General Public License. For more information about these matters, see the files named COPYING. This version of gphoto2 is using the following software versions and options: gphoto2 2.5.5 /usr/bin/clang, popt(m), exif, no cdk, no aa, jpeg, readline libgphoto2 220.127.116.11 all camlibs, /usr/bin/clang, ltdl, EXIF libgphoto2_port 0.10.0 /usr/bin/clang, ltdl, USB, serial without locking Downloading '1437595816717.jpeg' from folder '/store_00010001/DCIM/Camera'... *** Error *** PTP General Error *** Error (-1: 'Unspecified error') *** For debugging messages, please use the --debug option. Debugging messages may help finding a solution to your problem. If you intend to send any error or debug messages to the gphoto developer mailing list <firstname.lastname@example.org>, please run gphoto2 as follows: env LANG=C gphoto2 --debug --debug-logfile=my-logfile.txt -T -v Please make sure there is sufficient quoting around the arguments.
#1 Updated by Apparat Grande over 4 years ago
I can confirm this issue.
Darktable is also crashing very often when I open up the "import from camera" dialog a second time. Even if all of the images have a thumbnail image.
The first time all thumbnails are displayed and the import works fine. The second time some thumbnails are displayed and many others are not and darktable freezes (with the same SD card inserted).