Issue
I have several RaspberryPIs as remotes in VSCode via SSH. In some of them at some point the "search in files" feature has stoped working. It is only searching inside the opened files.
[EDIT] After further investigation I found out that on all the Raspberrys where the error occurs I can not install ripgrep. (E: Unable to locate package ripgrep) As VSCode is using ripgrep for searching this may be the cause but what is the solution then?
[EDIT2] I built and installed ripgrep manuall. No success. But maybe it is related to the debian version being 9.X
[EDIT3] I setup a completely new raspberry. There I was able to search in all files. Afer a couple of Monts suddenly it also stoped working there. So the problem is not dependent on ripgrep or debian version at all. The only factor seems to be the time the project is alive.
As several people have reported the same problem but the cirumstances are always different I tried the following solutions:
- Make sure the "book" icon is not checked (some users had that problem)
- Make sure it is not related to path lenght. Just one folder in ~ with file a.py and b.py (some user had that problem)
- Made sure there is nothing in the .gitignore file (some user had that problem)
- Made a new folder not inside a samba shared folder (some user had that problem)
- Deactivated all exensions on the remote
- Deactivated all non SSH related extensions on the PC
- Compared the setting on the broken remote to a working one. They are completely the same.
- deleted the .vscode-server folder on the remote to force VSCode to install it again
Solution
I had the exact same issue where global search failed on me yesterday. I installed vs code insiders from here: https://code.visualstudio.com/docs/?dv=win&build=insiders and it fixed it for me
Answered By - ihavearms Answer Checked By - Willingham (WPSolving Volunteer)