Bug 375770 - Creating tag from left panel causes error
Summary: Creating tag from left panel causes error
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Tags-Engine (show other bugs)
Version: 5.4.0
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-01-31 03:46 UTC by J-o-h-n-
Modified: 2017-02-04 09:48 UTC (History)
2 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description J-o-h-n- 2017-01-31 03:46:31 UTC
When using the left panel 'Enter tag here.' field to create a non-existing tag on multiple selected images, the following error dialog box happens:

|Tag creation Error
|An error occurred during tag creation:
|Tag Path		Error
|Earth2			Tag name already exists

And then the following apply dialog box:

|Apply changes?
|You have edited the metadata of XX images:
|-caption
|-tags
|Do you want to apply your changes?
|Always apply changes without confirmation

The second error (Apply changes) happens when one or more images are selected.  The first (Tag creation Error) and second (Apply changes) errors both happen when more than one image is selected.

It seems when multiple images are selected during tag creation, the tag is trying to be created for each individual file instead of created for the first and selected for the rest.

It seems there may be two separate issues here, the 'Tag creation Error' issue and the 'Apply changes' issue.  If selecting a pre-existing tag does not cause the apply changes dialog box, then creating a new tag should not cause the apply changes dialog box either.
Comment 1 J-o-h-n- 2017-01-31 03:50:19 UTC
This happens on both Windows 10 x64 and Ubuntu-Gnome 16.04 x64.
Comment 2 Maik Qualmann 2017-01-31 18:54:27 UTC
Git commit e23e4693169bf406e950e66d2377dee84a3ae866 by Maik Qualmann.
Committed on 31/01/2017 at 18:53.
Pushed by mqualmann into branch 'master'.

fix double signal from the AddTagsLineEdit

M  +10   -2    libs/tags/addtagslineedit.cpp

https://commits.kde.org/digikam/e23e4693169bf406e950e66d2377dee84a3ae866
Comment 3 Maik Qualmann 2017-01-31 19:01:07 UTC
I think you mean the right sidebar and not the left one? I could only see a double error box when an existing tag was created from the completer. The other problems I can not reproduce, possibly they are related to the double signal.

Maik
Comment 4 Maik Qualmann 2017-01-31 19:19:35 UTC
Tested again with the AppImage, yes the bug is now fixed. I close this bug now.

Maik
Comment 5 J-o-h-n- 2017-02-03 00:06:06 UTC
Sorry, I missed this one.  Yes, I did mean the right-panel, not the left.

When creating a new tag this way, is it intentional to force apply tags at the same time?
Comment 6 Maik Qualmann 2017-02-04 07:50:20 UTC
> When creating a new tag this way, is it intentional to force apply tags at
> the same time?

I think yes, I check the behavior but again with digikam-4.x.

Maik
Comment 7 Barbara Scheffner 2017-02-04 09:48:20 UTC
Whether tags should be force applied is debatable but since both ways have their advantages I would vote for leaving it the way it is.
Note that the appearance of the confirmation dialog depends on your settings in Configure digiKam/Miscellaneous/"Do not confirm when applying changes in the right sidebar" (Wording could be better perhaps, at least I have to think twice ;-)).