Bug 447896 - Dolphin search result duplicates
Summary: Dolphin search result duplicates
Status: RESOLVED DUPLICATE of bug 447119
Alias: None
Product: dolphin
Classification: Applications
Component: search (show other bugs)
Version: 21.12.0
Platform: Neon Linux
: NOR normal
Target Milestone: ---
Assignee: Dolphin Bug Assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-01-03 20:41 UTC by Peter Stein
Modified: 2022-01-06 10:48 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Dolphin search duplicate files result (148.35 KB, image/jpeg)
2022-01-03 20:41 UTC, Peter Stein
Details
duplicate search result in Dolphin (86.19 KB, image/jpeg)
2022-01-06 10:09 UTC, Peter Stein
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Stein 2022-01-03 20:41:54 UTC
Created attachment 145091 [details]
Dolphin search duplicate files result

SUMMARY
***
If I search in /usr/share/icons/breeze-dark for edit I get duplicate results with and without a thumbnail. It's no matter whether indexed or not-indexed folders, activated or deactivated baloo-service.


STEPS TO REPRODUCE
1. Open Dolphin, navigate to /usr/share/icons.
2. Search for something for example edit-


OBSERVED RESULT
duplicates files

EXPECTED RESULT
no duplicates

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 
Operating System: KDE neon 5.23
KDE Plasma Version: 5.23.4
KDE Frameworks Version: 5.89.0
Qt Version: 5.15.3
Kernel Version: 5.11.0-43-generic (64-bit)
Graphics Platform: X11
Comment 1 tagwerk19 2022-01-03 21:10:24 UTC
(In reply to Peter Stein from comment #0)
> If I search in /usr/share/icons/breeze-dark for edit I get duplicate results
> with and without a thumbnail. It's no matter whether indexed or not-indexed
> folders, activated or deactivated baloo-service.
If you are searching "from" /usr/share/icons/breeze-dark you won't have indexed these folders. (That is, unless you've configured baloo to index more than your home directory). That means Dolphin goes off to try and find results "there and then", running a filenamesearch rather than a baloosearch. 

The gotscha is filenamesearch follows symlinks (baloo goes out its way to avoid doing this), I'd suggest exploring the breeze-dark folders and see if they contain collections of symlinks. I see that they do on my Fedora system...
Comment 2 tagwerk19 2022-01-03 21:17:04 UTC
Probably a slight twist on "Case 3"  in Bug 447119

This uses the example of a symlink under ~/Desktop pointing to ~/Documents but I think it could be the same issue.
Comment 3 tagwerk19 2022-01-05 13:08:39 UTC
I'm assuming the link to the summary is OK, will flag as duplicate

*** This bug has been marked as a duplicate of bug 447119 ***
Comment 4 Peter Stein 2022-01-06 10:09:02 UTC
Created attachment 145152 [details]
duplicate search result in Dolphin

I think this error does not matter with symlinks. I am searching in folder /usr/share/breeze-dark for a file document-edit-decrypt-verify.svg. This file has no symlinks in the folder breeze-dark. Also is this folder not indexed. The result of the search can be seen in the attachment. /usr/share/icons/breeze-dark/actions/32/document-edit-decrypt-verify.svg is duplicated.
This problem didn't exist in the Dolphin version 21.08.3
Comment 5 tagwerk19 2022-01-06 10:48:06 UTC
(In reply to Peter Stein from comment #4)
> ... Also is this folder not indexed.
That's fine, Dolphin will do its "own search" (with filenamesearch rather than asking baloo)

> ... I think this error does not matter with symlinks.
You might need to look to see if you have symlinks under
    /usr/share/icons/breeze-dark/actions

On my system, there's something of a web:
    [test@fedora35 actions]$ ls -l
    total 24
    drwxr-xr-x. 1 root root   350 Dec 26 15:31 12
    drwxr-xr-x. 1 root root 69718 Dec 26 15:31 16
    lrwxrwxrwx. 1 root root     2 Dec  4 17:55 16@2x -> 16
    lrwxrwxrwx. 1 root root     2 Dec  4 17:55 16@3x -> 16
    drwxr-xr-x. 1 root root 77946 Dec 26 15:31 22
    lrwxrwxrwx. 1 root root     2 Dec  4 17:55 22@2x -> 22
    lrwxrwxrwx. 1 root root     2 Dec  4 17:55 22@3x -> 22
    drwxr-xr-x. 1 root root 11204 Dec 26 15:31 32
    lrwxrwxrwx. 1 root root     2 Dec  4 17:55 32@2x -> 32
    lrwxrwxrwx. 1 root root     2 Dec  4 17:55 32@3x -> 32
    drwxr-xr-x. 1 root root   414 Dec 26 15:31 48
    drwxr-xr-x. 1 root root   154 Dec 26 15:31 64
    drwxr-xr-x. 1 root root 11400 Dec 26 15:31 symbolic

I was looking at Fedora 35. If I look at Neon, yes, it looks the same.

Imagine that you are starting your search "in" /usr/share/icons/breeze-dark and searching down into each folder in turn, you could quite easily see many copies of document-edit-decrypt-verify.svg

> ... This problem didn't exist in the Dolphin version 21.08.3
That's interesting.

I've noticed the difference in behaviour (between baloo and "there and then" searches) for a while. The question is... where do I have a 21.08.03 so I can check