Bug 406227

Summary: Picture without any tag are not listed with button "No Tags"
Product: [Applications] digikam Reporter: Daniel Ouin <daniel.ouin>
Component: Tags-EngineAssignee: Digikam Developers <digikam-bugs-null>
Status: RESOLVED FIXED    
Severity: grave CC: metzpinguin
Priority: NOR    
Version First Reported In: 6.0.0   
Target Milestone: ---   
Platform: Microsoft Windows   
OS: Microsoft Windows   
Latest Commit: Version Fixed/Implemented In: 6.1.0
Sentry Crash Report:
Attachments: Screen shot of "No tags" bug
JPEG Picture without any tag
clearing filters and trash...
2nd part of psr zip file...
DebugView log

Description Daniel Ouin 2019-04-04 17:49:44 UTC
Created attachment 119242 [details]
Screen shot of "No tags" bug

SUMMARY
In "Tags" tab, no picture is listed when I select the radio button "No tags", whereas I have few non-tagged pictures.

STEPS TO REPRODUCE
1. Launch Digikam
2. Click on tab "Tags" on the left
3. Click on radio button "No tags"

OBSERVED RESULT
No picture is listed.


EXPECTED RESULT
Picture not assigned to any tag (i.e. for example newly imported pictures) should appear in the list.

SOFTWARE/OS VERSIONS
Windows: WIN 10
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
This feature was working properly with the previous version. This feature is very helpful when importing new picture and for checking the result of categorization at any time.
Comment 1 Maik Qualmann 2019-04-04 17:58:29 UTC
In the right sidebar a MIME type filter is active (no RAW files) which probably filters the display of items. The no tags search works here without problems.

Maik
Comment 2 Daniel Ouin 2019-04-04 18:40:50 UTC
Created attachment 119245 [details]
JPEG Picture without any tag
Comment 3 Daniel Ouin 2019-04-04 18:43:42 UTC
In fact, I have RAW files and JPEG files in my folders. I do not want Digikam to categorize RAW files. That's why I set this MIME type filter. I attached above an example of a JPEG picture that do not have any tag. I am expecting to see this picture in "Tag" tab when "No tags" button is activated.
Comment 4 Daniel Ouin 2019-04-04 18:46:40 UTC
This not tagged file is a GIF file, not a JPEG file. Sorry for this mistake.
But it does not change any thing in this bug....
Comment 5 Maik Qualmann 2019-04-04 19:11:00 UTC
Can you please clear the filter on the status bar with press the trash icon and try again.

Maik
Comment 6 Daniel Ouin 2019-04-05 06:27:45 UTC
Created attachment 119252 [details]
clearing filters and trash...

Thank you Maik for the proposition.
I cleared all filters. I checked the trash, but no picture was there.
Coming back to Tag tab afterwards, I can see that it is the same.
I attach 1 zip file generated by PSR, converted into 2 pdf files in order to fit size limitation. I hope this will help you...
Comment 7 Daniel Ouin 2019-04-05 06:28:42 UTC
Created attachment 119253 [details]
2nd part of psr zip file...
Comment 8 Maik Qualmann 2019-04-05 10:24:26 UTC
Do you use SQLite or MySQL (internal or external) as database?

Maik
Comment 9 Daniel Ouin 2019-04-05 12:40:01 UTC
I use SQLite database.
Comment 10 Maik Qualmann 2019-04-05 19:06:25 UTC
Can you download and start DebugView from Microsoft? Then post the log from the start of digiKam until no tags have been selected.

Maik
Comment 11 Daniel Ouin 2019-04-06 12:32:25 UTC
Created attachment 119270 [details]
DebugView log

I started at first DebugView, then Digikam tool.
In Digikam, I set MIME type filter to "No RAW files". Then, I switch the Tabs tab button to "No tags".
Best regards
Daniel
Comment 12 Maik Qualmann 2019-04-06 19:43:39 UTC
Git commit ef50db74dfb2cdd4f021ac779279d2d9b4c34e8f by Maik Qualmann.
Committed on 06/04/2019 at 19:42.
Pushed by mqualmann into branch 'master'.

fix SQL query to filter out internal tags
FIXED-IN: 6.1.0

M  +2    -1    NEWS
M  +1    -1    core/app/views/sidebar/leftsidebarwidgets.cpp
M  +8    -0    core/libs/database/item/query/itemquerybuilder.cpp

https://commits.kde.org/digikam/ef50db74dfb2cdd4f021ac779279d2d9b4c34e8f
Comment 13 Maik Qualmann 2019-04-06 19:52:27 UTC
Another note, which is visible in the log. It is not necessary and should not be made to add each subfolder as a collection. Only the top folder is enough.

Maik