Bug 379833 - Sidecar files are not being created for some files
Summary: Sidecar files are not being created for some files
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Metadata-Sidecar (show other bugs)
Version: 5.5.0
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-05-14 23:38 UTC by Andrius
Modified: 2017-05-23 20:43 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In: 5.6.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrius 2017-05-14 23:38:48 UTC
I just added many video files (mp4) to a folder in digiKam collection and noticed that xmp sidecar was created for only one file.

If I for example add geolocation to the file that has xmp I get no GUI error and GPS coordinates being added to the sidecar.
Here is the output of the terminal:
---
digikam.geoiface: "setting backend googlemaps"
digikam.geoiface: "ROADMAP"
digikam.geoiface: located data:  QUrl("file:///usr/share/digikam/geoiface/backend-googlemaps.html")
digikam.geoiface: Maps Loading Progress:  10 %
digikam.geoiface: "ASSERT: isReady() - /home/abuild/rpmbuild/BUILD/digikam-5.5.0/core/utilities/geolocation/geoiface/backends/backendgooglemaps.cpp:402"
digikam.geoiface: Maps Loading Progress:  50 %
digikam.geoiface: ----
digikam.general: 0 1
digikam.geoiface: ----
digikam.general: 1 2
digikam.geoiface: Maps Loading Progress:  100 %
digikam.geoiface: Map Loading Completed:  true
digikam.geoiface: "ROADMAP"
digikam.geoiface: "backend googlemaps is ready!"
digikam.geoiface: "googlemaps:8"
digikam.geoiface: 8
digikam.geoiface: QVariant(QPersistentModelIndex, QModelIndex(0,0,0x0,Digikam::GPSImageModel(0x4033410))) QSize(32, 58)
digikam.geoiface: QVariant(QPersistentModelIndex, QModelIndex(1,0,0x0,Digikam::GPSImageModel(0x4033410))) QSize(32, 58)
digikam.geoiface: ----
digikam.geoiface: ----
digikam.geoiface: ----
digikam.geoiface: "ASSERT: currentBounds.first.lat() < currentBounds.second.lat() - /home/abuild/rpmbuild/BUILD/digikam-5.5.0/core/utilities/geolocation/geoiface/abstractmarkertiler.cpp:256"
digikam.geoiface: "ASSERT: currentBounds.first.lon() < currentBounds.second.lon() - /home/abuild/rpmbuild/BUILD/digikam-5.5.0/core/utilities/geolocation/geoiface/abstractmarkertiler.cpp:257"
digikam.geoiface: "level 4: 0 non empty tiles sorted into 0 clusters (0 searched)"
digikam.geoiface: start updateclusters
digikam.geoiface: end updateclusters
digikam.metaengine: Cannot load metadata from file   (Error # 11 :  /mnt/data/FamilyPictures/2016/2016-10/20161023_191434_x264.mp4: The file contains data of an unknown image type
digikam.geoiface: ----
digikam.metaengine: MetaEngine::metadataWritingMode 3
digikam.metaengine: Will write Metadata to file "/mnt/data/FamilyPictures/2016/2016-10/20161023_191434_x264.mp4"
digikam.metaengine: Cannot save metadata to image using Exiv2   (Error # 11 :  /mnt/data/FamilyPictures/2016/2016-10/20161023_191434_x264.mp4: The file contains data of an unknown image type
digikam.metaengine: Metadata for file "20161023_191434_x264.mp4" written to file.
digikam.metaengine: Will write XMP sidecar for file "20161023_191434_x264.mp4"
digikam.metaengine: wroteComment:  false
digikam.metaengine: wroteEXIF:  true
digikam.metaengine: wroteIPTC:  true
digikam.metaengine: wroteXMP:  true
digikam.metaengine: Metadata for file "20161023_191434_x264.mp4" written to XMP sidecar.
digikam.geoiface: ----
digikam.general: 0 1
digikam.geoiface: "ASSERT: currentBounds.first.lat() < currentBounds.second.lat() - /home/abuild/rpmbuild/BUILD/digikam-5.5.0/core/utilities/geolocation/geoiface/abstractmarkertiler.cpp:256"
digikam.geoiface: "ASSERT: currentBounds.first.lon() < currentBounds.second.lon() - /home/abuild/rpmbuild/BUILD/digikam-5.5.0/core/utilities/geolocation/geoiface/abstractmarkertiler.cpp:257"
digikam.geoiface: "level 4: 0 non empty tiles sorted into 0 clusters (0 searched)"
digikam.geoiface: start updateclusters
digikam.geoiface: end updateclusters
---

If I try to add geolocation to another file from this folder I get the error "Failed to open file" after pressing "Save". No sidecar being created.
Here is the output of the terminal:
---
digikam.geoiface: "setting backend googlemaps"
digikam.geoiface: "ROADMAP"
digikam.geoiface: located data:  QUrl("file:///usr/share/digikam/geoiface/backend-googlemaps.html")
digikam.geoiface: Maps Loading Progress:  10 %
digikam.metaengine: Cannot load metadata from file   (Error # 11 :  /mnt/data/FamilyPictures/2016/2016-10/20161015_093414_x264.mp4: The file contains data of an unknown image type
digikam.metaengine: Cannot load metadata from file   (Error # 11 :  /mnt/data/FamilyPictures/2016/2016-10/20161015_093414_x264.mp4: The file contains data of an unknown image type
digikam.geoiface: "ASSERT: isReady() - /home/abuild/rpmbuild/BUILD/digikam-5.5.0/core/utilities/geolocation/geoiface/backends/backendgooglemaps.cpp:402"
digikam.geoiface: Maps Loading Progress:  50 %
digikam.geoiface: ----
digikam.general: 1 2
digikam.general: 0 1
digikam.geoiface: Maps Loading Progress:  100 %
digikam.geoiface: Map Loading Completed:  true
digikam.geoiface: "ROADMAP"
digikam.geoiface: "backend googlemaps is ready!"
digikam.geoiface: "googlemaps:8"
digikam.geoiface: 8
digikam.geoiface: QVariant(QPersistentModelIndex, QModelIndex(1,0,0x0,Digikam::GPSImageModel(0x3a3d000))) QSize(32, 58)
digikam.geoiface: QVariant(QPersistentModelIndex, QModelIndex(0,0,0x0,Digikam::GPSImageModel(0x3a3d000))) QSize(32, 58)
digikam.geoiface: ----
digikam.geoiface: ----
digikam.geoiface: ----
digikam.geoiface: "ASSERT: currentBounds.first.lat() < currentBounds.second.lat() - /home/abuild/rpmbuild/BUILD/digikam-5.5.0/core/utilities/geolocation/geoiface/abstractmarkertiler.cpp:256"
digikam.geoiface: "ASSERT: currentBounds.first.lon() < currentBounds.second.lon() - /home/abuild/rpmbuild/BUILD/digikam-5.5.0/core/utilities/geolocation/geoiface/abstractmarkertiler.cpp:257"
digikam.geoiface: "level 4: 0 non empty tiles sorted into 0 clusters (0 searched)"
digikam.geoiface: start updateclusters
digikam.geoiface: end updateclusters
digikam.metaengine: Cannot load metadata from file   (Error # 11 :  /mnt/data/FamilyPictures/2016/2016-10/20161015_093414_x264.mp4: The file contains data of an unknown image type
digikam.geoiface: ----
digikam.general: 0 1
digikam.geoiface: "ASSERT: currentBounds.first.lat() < currentBounds.second.lat() - /home/abuild/rpmbuild/BUILD/digikam-5.5.0/core/utilities/geolocation/geoiface/abstractmarkertiler.cpp:256"
digikam.geoiface: "ASSERT: currentBounds.first.lon() < currentBounds.second.lon() - /home/abuild/rpmbuild/BUILD/digikam-5.5.0/core/utilities/geolocation/geoiface/abstractmarkertiler.cpp:257"
digikam.geoiface: "level 4: 0 non empty tiles sorted into 0 clusters (0 searched)"
digikam.geoiface: start updateclusters
digikam.geoiface: end updateclusters
---

I did try creating an empty sidecar manually but I got the same error and no information was written to it.

All files have same writing permissions.
All videos taken on same camera.
digiKam set to write to sidecar for read-only images.
Any ideas on why is this happening?
Comment 1 Andrius 2017-05-15 14:49:10 UTC
Please let me know if you need any further information from me to investigate the issue.
I think this issue might be related to this one: https://bugs.kde.org/show_bug.cgi?id=366247
Comment 2 Maik Qualmann 2017-05-23 19:13:02 UTC
Git commit eff4ffdf83c336c28b8398c5c24f7010aa69895b by Maik Qualmann.
Committed on 23/05/2017 at 19:11.
Pushed by mqualmann into branch 'master'.

ignore loading error of metadata if sidecar file writing enabled
FIXED-IN: 5.6.0

M  +2    -1    NEWS
M  +7    -1    utilities/geolocation/editor/items/gpsimageitem.cpp

https://commits.kde.org/digikam/eff4ffdf83c336c28b8398c5c24f7010aa69895b
Comment 3 Andrius 2017-05-23 20:43:02 UTC
Hello Maik, thank you for fixing this. I will test it as soon as an updated 5.6 appimage available. My only concern is why is the error popping up for some files while there is no error for other files. All files in the folder are very similar (same camera, same encoding, etc.)