Bug 478991 - BQM removes tags and ratings
Summary: BQM removes tags and ratings
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Plugin-Bqm-Script (show other bugs)
Version: 8.2.0
Platform: Appimage Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-12-25 11:03 UTC by ٩(̾●̮̮̃̾•̃̾)۶
Modified: 2023-12-27 14:18 UTC (History)
2 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description ٩(̾●̮̮̃̾•̃̾)۶ 2023-12-25 11:03:53 UTC
SUMMARY
BQM removes all tags and star ratings.

STEPS TO REPRODUCE
1. Select file with tags and stars
2. Run BQM script with setting to overwrite file

OBSERVED RESULT
3. File is converted but tags and stars are removed

EXPECTED RESULT
3. File is converted and tags and stars are retained

Appeared in appImage 8.2.0
Comment 1 Maik Qualmann 2023-12-25 20:39:03 UTC
Please post your script that you are using. The database metadata is applied to the target image. I can't reproduce any issue.
Have you considered that if your script doesn't create a new image, you have to first copy the input image to the target image in the script?

https://docs.digikam.org/en/batch_queue/custom_script.html#custom-script

Maik
Comment 2 ٩(̾●̮̮̃̾•̃̾)۶ 2023-12-26 11:01:12 UTC
Example script which worked perfectly before is as simple as:

cp $INPUT $OUTPUT
convert -geometry 2048x2048 -sharpen 2 -quality 85 -strip $INPUT $OUTPUT

I can't grasp the nuances you suggest from documentation given (first copying input to target).
Comment 3 ٩(̾●̮̮̃̾•̃̾)۶ 2023-12-26 11:03:45 UTC
Sry, I sent wrong script. I'll check one thing from the correct one before sending it.
Comment 4 ٩(̾●̮̮̃̾•̃̾)۶ 2023-12-26 11:06:05 UTC
Ok, I have workflow where I first run custom shell script then use built in "Assign Labels" feature to mark it with colour label, which creates the problem. Running custom script only works fine. So the problem is actually in this built in feature.
Comment 5 Maik Qualmann 2023-12-26 16:28:02 UTC
Git commit ec5521fd8a96582d2d173dbef65516e8343a11bb by Maik Qualmann.
Committed on 26/12/2023 at 17:27.
Pushed by mqualmann into branch 'master'.

adjust metadata scanning in the BQM
FIXED-IN: 8.3.0

M  +1    -1    NEWS
M  +12   -2    core/utilities/queuemanager/manager/actionthread.cpp

https://invent.kde.org/graphics/digikam/-/commit/ec5521fd8a96582d2d173dbef65516e8343a11bb
Comment 6 Maik Qualmann 2023-12-26 19:49:27 UTC
Another note on Comment 2, copying from $INPUT to $OUTPUT is not necessary in the example because "convert" creates a file. Copying is only necessary if no new file is created, BQM always expects a new file on $OUTPUT.

Maik
Comment 7 ٩(̾●̮̮̃̾•̃̾)۶ 2023-12-27 14:18:00 UTC
Thx for explanation. Will try to simplify my scripts. (Still hoping for feature to run these scripts directly by left clicking images. You have abundance of technical features included which is great, but at some places usability improvements would be very helpful. Thank you for your work.)