Bug 437175 - Use media file timestamp when creating sidecar
Summary: Use media file timestamp when creating sidecar
Status: RESOLVED INTENTIONAL
Alias: None
Product: digikam
Classification: Applications
Component: Metadata-Sidecar (show other bugs)
Version: 7.2.0
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-05-15 21:00 UTC by Jozef Říha
Modified: 2021-05-16 07:54 UTC (History)
1 user (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jozef Říha 2021-05-15 21:00:57 UTC
SUMMARY
It would be nice if digiKam syncs modification time of newly created sidecar with referenced media file.

STEPS TO REPRODUCE
1. Enable sidecar writes
2. Select a video file, add metadata
3. Have metadata saved to file

OBSERVED RESULT
Modified time of generated sidecar file has current timestamp

EXPECTED RESULT
Modified time of generated sidecar file matches with mtime of file it belongs to

SOFTWARE/OS VERSIONS
Arch Linux, x86_64 rolling
Comment 1 Maik Qualmann 2021-05-15 21:22:15 UTC
No, this is the only way for us to determine if the sidecar or image has been changed externally. We use the latest modification date for the database from the sidecar or image.

Maik
Comment 2 Maik Qualmann 2021-05-15 21:38:23 UTC
Another point are backup programs, if we change the modification date of a file, although it has not been changed, it is unnecessarily included in the backup.

Maik
Comment 3 Jozef Říha 2021-05-15 21:49:44 UTC
Not sure if I understand correctly. Maybe I missing a point?

Initial state:

- movie.avi     - mtime: 2003-01-01
- no .xmp file

Enabling sidecar in digiKam + edit of metadata + sync to file metadata:

- movie.avi     - mtime: 2003-01-01
- movie.avi.xmp - mtime: 2021-05-15 (current date)

Backup sw:
- sees a new file (.xmp) -> file is sent to backup, movie.avi is not processed (mtime stays the same)

digiKam:
- can keep track of sidecar changes internally (in the db) or write this info into sidecar file itself
Comment 4 Maik Qualmann 2021-05-16 07:05:04 UTC
I just tested the behavior of Darktable. Here, too, the sidecar has the current date.

Maik
Comment 5 Jozef Říha 2021-05-16 07:54:08 UTC
Thanks for checking, Maik. Looks like it works the same way across all known tools - also tried with Geeqie and exiftool. Might be something like a de-facto standard.