Hi All,
What is the proper procedure - please step by step! - it might seem obvious to you, but I can't figure it out! - to: 1. Rearrange the tag tree . . . 2. Successfully saving the tagslist to a sidecar file or to the image file . . . 3. Be able to close and open digiKam and see the same tag tree that was displayed before closing digiKam? Some background: My images already have embedded digiKam tagslist tags. But I haven't used digiKam in a long time. I installed digiKam Version 5.7.0 from Gentoo Portage, and imported some images into a fresh database. I'm having a great deal of difficulty with the digikam tagslist hierarchy: 1. After rearranging the tag tree, and then reopening digiKam, the tag tree is again in a mess. 2. Some tags aren't saved to the xmp sidecar file. I set digiKam up to only write to xmp sidecar files and to only write the Xmp.digiKam.TagsList tag, which is a wonderful new option if it actually works. Selecting some images and then choosing "Item/Write Metadata to Selected Images" does result in the file manager showing that the xmp sidecar was indeed modified. But not all the tags are being written to the sidecar file. 3. After giving up on writing only to the xmp sidecar file, I wrote all the tags out to the image files and closed and reopened digikam. And now a lot of tags are missing, plus the remaining tags still aren't as I actually left them when I closed digiKam. And some tags still refuse to be saved to the image file and also refuse to be saved to the sidecar file. 4. So I suppose the next step is to delete all the image files and start again with the backup files that still have the old tags. But this seems rather pointless. FWIW, I've been working on this problem for several hours last night, several more hours this morning, and also for several years (https://bugs.kde.org/show_bug.cgi?id=268688, https://bugs.kde.org/show_bug.cgi?id=309058). Best, Elle |
On 10/21/2017 12:23 PM, Elle Stone wrote:
> 1. Rearrange the tag tree . . . > > 2. Successfully saving the tagslist to a sidecar file or to the image > file . . . > > 3. Be able to close and open digiKam and see the same tag tree that was > displayed before closing digiKam? Perhaps this terminal output from moving a portion of the tag tree might be relevant: digikam.general: Delete Shortcut assigned to tag 56 digikam.dbengine: Failure executing query: "UPDATE Tags SET pid=? WHERE id=?;" Error messages: "Unable to fetch row" "UNIQUE constraint failed: TagsTree.id, TagsTree.pid" 19 1 Bound values: (QVariant(int, 81), QVariant(int, 56)) |
On 10/21/2017 02:19 PM, Elle Stone wrote:
> On 10/21/2017 12:23 PM, Elle Stone wrote: >> 1. Rearrange the tag tree . . . >> >> 2. Successfully saving the tagslist to a sidecar file or to the image >> file . . . >> >> 3. Be able to close and open digiKam and see the same tag tree that >> was displayed before closing digiKam? > > Perhaps this terminal output from moving a portion of the tag tree might > be relevant: > > digikam.general: Delete Shortcut assigned to tag 56 > digikam.dbengine: Failure executing query: > "UPDATE Tags SET pid=? WHERE id=?;" > Error messages: "Unable to fetch row" "UNIQUE constraint failed: > TagsTree.id, TagsTree.pid" 19 1 > Bound values: (QVariant(int, 81), QVariant(int, 56)) > In case anyone else tries to rearrange tags and tag hierarchies that somehow were split, start digiKam from the command line and monitor for the above lines. If you see "UNIQUE constraint failed" then whatever rearranging that you just did, didn't actually get done. The solution seems to be to rename the affected tags (perhaps append "2" or "a" or whatever), on all levels of the misplaced tag tree. And then only move the lowest level tags, if necessary to a newly created tag that can later be reconsolidated with an existing tag. If the tag hierarchies were split "cleanly" - no overlap of subtags - then I think it's possible to move an entire tag "branch" at once. It's important to disable all writing to the image files and sidecar files before rearranging, same as back in 2012: https://mail.kde.org/pipermail/digikam-users/2012-November/017036.html When finally writing everything back to the image and sidecar files, I only allowed digiKam to write the "tagslist" metadata. This is a very nice feature that wasn't available back in 2012. By default digiKam writes a lot of tags for compatibility with other programs, and the first time I tried to write the newly rearranged tags to the image files, and then closed and reopened digiKam, digiKam pulled a lot of extra non-hierarchical tags that it just wrote, right into the database as "new tags", making a worse mess than what I started with. Fortunately I had a backup of the image files . . . Before doing anything, I used exiftool to remove *all* tags-related metadata from the image files, except for the "tagslist" xmp metadata It should not be such hard work to rearrange tag hierarchies. Best, Elle |
On 10/21/2017 04:46 PM, Elle Stone wrote:
> > If the tag hierarchies were split "cleanly" - no overlap of subtags - > then I think it's possible to move an entire tag "branch" at once. In reality this seems impossible to do. I described the procedures I used to try to move a branch in the fifth post in this forum thread: https://discuss.pixls.us/t/rearranging-the-digikam-tag-tree/5405/5 If I'm making a mistake in the procedure for moving a sub-branch up to be a top-level branch, then any help in getting the procedure correct would be very much appreciated. Otherwise, if this really is impossible to do, I want to update a couple of digiKam bug reports. Best regards, Elle -- http://ninedegreesbelow.com Color management and free/libre photography |
Free forum by Nabble | Edit this page |