Bug 435689

Summary: The 'Stop' button in the 'Search and replace' panel no longer works properly
Product: [Applications] kate Reporter: Kishore Gopalakrishnan <kishore96>
Component: searchAssignee: KWrite Developers <kwrite-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: kare.sars, nate
Priority: NOR    
Version First Reported In: 21.03.90   
Target Milestone: ---   
Platform: Arch Linux   
OS: Other   
Latest Commit: Version Fixed/Implemented In: 21.04
Sentry Crash Report:

Description Kishore Gopalakrishnan 2021-04-13 13:23:00 UTC
SUMMARY
Clicking the 'Stop' button in the 'search and replace' panel greys out the 'search and replace' panel. This means that after cancelling a search, the user cannot perform another search without restarting Kate.

STEPS TO REPRODUCE
1. Open the 'Search and replace' panel
2. Type in a string in the 'search' textbox
3. As the search scope, select 'In folder'
4. Select a big folder as the folder to search (so that the search will not finish before you actually click the 'stop' button; I chose '/' as the folder)
5. Begin the search
6. Press the 'stop' button

OBSERVED RESULTS
The stop button gets highlighted, and the whole panel becomes greyed out. The user cannot interact with the 'Search and Replace' panel. Pressing the 'Stop' button again has no effect. I can interact normally with the text area and the menu (File, Edit etc.).

EXPECTED RESULTS
The 'search and replace' panel should remain usable after cancelling a search.

SOFTWARE VERSIONS
Operating System: Arch Linux
KDE Plasma Version: 5.21.4
KDE Frameworks Version: 5.81.0
Qt Version: 5.15.2
Kernel Version: 5.10.29-1-lts
OS Type: 64-bit
Graphics Platform: X11
Processors: 4 × AMD EPYC-Rome Processor
Memory: 1.4 GiB of RAM
Graphics Processor: virgl

ADDITIONAL INFORMATION
I could not find any processes in the background using a lot of CPU after cancelling the search, so it looks like while the search gets cancelled, the UI doesn't get updated.
Comment 1 Kåre Särs 2021-04-14 09:49:32 UTC
Git commit fce870476ef824d1ddaa021bc9e057dd8b8a5aa4 by Kåre Särs.
Committed on 14/04/2021 at 09:42.
Pushed by sars into branch 'master'.

Fix S&R not recovering from canceled folder search

M  +4    -5    addons/search/FolderFilesList.cpp
M  +0    -3    addons/search/FolderFilesList.h
M  +2    -2    addons/search/plugin_search.cpp

https://invent.kde.org/utilities/kate/commit/fce870476ef824d1ddaa021bc9e057dd8b8a5aa4
Comment 2 Kåre Särs 2021-04-14 09:54:11 UTC
Git commit ba1983083fb8f1925deba070c75e33a654933fd8 by Kåre Särs.
Committed on 14/04/2021 at 09:50.
Pushed by sars into branch 'release/21.04'.

Fix S&R not recovering from canceled folder search

M  +4    -5    addons/search/FolderFilesList.cpp
M  +0    -3    addons/search/FolderFilesList.h
M  +2    -2    addons/search/plugin_search.cpp

https://invent.kde.org/utilities/kate/commit/ba1983083fb8f1925deba070c75e33a654933fd8