Bug 301482 - xmp sidecar files not being generated for .3xf raw file type
Summary: xmp sidecar files not being generated for .3xf raw file type
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Metadata-Sidecar (show other bugs)
Version: 2.6.0
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-06-09 02:10 UTC by Danni Coy
Modified: 2012-06-28 09:47 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 2.7.0
Sentry Crash Report:


Attachments
screenshot of metadata settings for digikam (93.66 KB, image/jpeg)
2012-06-10 12:45 UTC, Danni Coy
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Danni Coy 2012-06-09 02:10:27 UTC
I am seeing sidecar files being generated for every file type in my collection except the sigma (x3f) raw files for my camera. I have digikam set to write to both the image and a sidecar file and I have writing to metadata to raw files enabled (for some of the other types of raw files in my collection).

Reproducible: Always

Steps to Reproduce:
1. add tag to a x3f raw file in Digikam. 
2. (optional) use image -> write metadata to selected images 
3. check folder in dolphin for sidecar file.
Actual Results:  
sidecar file should appear in the same folder as the image

Expected Results:  
sidecar file was never created
Comment 1 caulier.gilles 2012-06-09 17:11:27 UTC
Which digiKam metadata settings you use ? Look into Setup/Metadata dialog for details...

XMP side car files are managed properly with other image mime type, as NEF, CR2, PNG, JPG ?

Gilles Caulier
Comment 2 Danni Coy 2012-06-09 23:34:56 UTC
jpeg,tif,png, CR2 (cannon raw)  RAF (fuji raw)- yes sidecar files are being generated
gimp xcf (no sidecar file).
x3f (sigma raw) no sidecar file.

all options for generating metadata are ticked 
read data from sidecar files is checked
write data to sidecar files is checked and set to "write to image and sidecar file"
write data to raw files (experimental) is checked.
update timestamp is not checked
Comment 3 Danni Coy 2012-06-10 00:02:53 UTC
also while I am at it .dds (which I added the extension into digikam for myself and will tag and edit fine) do not generate sidecar files.
Comment 4 caulier.gilles 2012-06-10 10:55:58 UTC
There is no reason technically than no sidecar is not generated for specific file as XCF or X3F. Can you take a screen-shots of your setup metadata config panel ? 

Also, i would to know which version of Exiv2 and libkexiv2 you use. Go to Help/Components Info for details.

And finally, please run kdebugdialog and turn on KExiv2 debug space. Now, run digiKam into a console and reproduce the problem. Please post the console trace here...

Gilles Caulier
Comment 5 Danni Coy 2012-06-10 12:45:51 UTC
Created attachment 71698 [details]
screenshot of metadata settings for digikam

could it be possible that digikam is trying to write to the raw file and when that fails it is forgetting to write the sidecar file?
Comment 6 caulier.gilles 2012-06-10 13:12:18 UTC
>could it be possible that digikam is trying to write to the raw file and when that fails it is forgetting to write the sidecar file?

Yes i suspect this dysfunction on your computer. In fact this part is manage in Exiv2 KDE interface written by digiKam team : libkexiv2. It's important to know libkexiv2 version used by digiKam (Help/Components Info), because if i'm not too wrong, it have been fixed something like this in libkexiv2 few month ago. Perhaps libkexiv2 form kdegraphics/libs, released with KDE, is a little bit too old...

Gilles Caulier
Comment 7 Danni Coy 2012-06-10 13:21:34 UTC
libkexiv is at 2.1.0
exiv2 is at 0.22 (looking at package version in Kubuntu)

The debug output from kexiv2 is definately showing a problem...

digikam(13985)/kio (Scheduler) KIO::SchedulerPrivate::jobFinished: KIO::SpecialJob(0x53f51a0) KIO::Slave(0x2b34910)
digikam(13985)/kdecore (trader) KMimeTypeTrader::query: query for mimeType  "image/x-sigma-x3f" ,  "Application"  : returning  6  offers
digikam(13985)/kdecore (trader) KMimeTypeTrader::query: query for mimeType  "image/x-sigma-x3f" ,  "Application"  : returning  6  offers
digikam(13985)/KEXIV2 KExiv2Iface::KExiv2::KExiv2Priv::printExiv2ExceptionError: Cannot load metadata using Exiv2   (Error # 11 :  /home/danni/Pictures/sd1m/9000/_SDI8961.X3F: The file contains data of an unknown image type
digikam(13985)/digikam (core) Digikam::DMetadata::setImageTitles: ""  ==> Title:  QMap()
digikam(13985)/digikam (core) Digikam::DMetadata::setImageComments: ""  ==> Comment:  QMap()
digikam(13985)/digikam (core) Digikam::DMetadata::setImagePickLabel: ""  ==> Pick Label:  0
digikam(13985)/digikam (core) Digikam::DMetadata::setImageColorLabel: ""  ==> Color Label:  0
digikam(13985)/digikam (core) Digikam::DMetadata::setImageRating: Rating value to write is out of range!
digikam(13985)/KEXIV2 KExiv2Iface::KExiv2::setIptcKeywords:   ==> Iptc Keywords:  performer,juggle,acordian
digikam(13985)/KEXIV2 KExiv2Iface::KExiv2::applyChanges: Failed to apply changes: file path is empty!
Comment 8 Danni Coy 2012-06-10 13:23:17 UTC
So I should try grabbing kexiv2 from git then?
Comment 9 caulier.gilles 2012-06-10 13:24:32 UTC
The current implementation separate well the way to write into file :

https://projects.kde.org/projects/kde/kdegraphics/libs/libkexiv2/repository/revisions/master/entry/libkexiv2/kexiv2.cpp#L428

and the way to write sidecar :

https://projects.kde.org/projects/kde/kdegraphics/libs/libkexiv2/repository/revisions/master/entry/libkexiv2/kexiv2.cpp#L438

If the first fails, the second is done as well...

Gilles Caulier
Comment 10 caulier.gilles 2012-06-10 13:27:26 UTC
Exiv2 version is fine.

libkexiv2 is too old... I think it's fixed with 2.2.x.

Can you try to recompile yourself digiam Software Collection 2.6.0 which include last libkexiv2 ?

Gilles Caulier
Comment 11 Danni Coy 2012-06-10 14:36:19 UTC
ok - i managed to jimmy a newer version of libkexiv2 into my system and can confirm that I can now write sidecar files for any format. Thanks for your help, I am off to back up 15,000 raw files.
Comment 12 caulier.gilles 2012-06-10 15:08:08 UTC
ok. I close this file now.

Gilles Caulier