-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Symlinks from wine result in walker infinite loop #4015
Comments
I reproduced the issue with The Tools like cd ~/.local/state/fnm_multishells
find . -type l -depth 1 | wc -l
4608
# fzf version: 0.55.0
unset FZF_DEFAULT_COMMAND
time command fzf --walker=file,follow --filter ''
user=86.46s system=241.46s cpu=232% total=2:21.14
# fd version: 10.2.0
time command fd --follow --color=never
user=163.76s system=582.79s cpu=496% total=2:30.25
# ripgrep version: 14.1.0
time command rg --follow --files --color=never
user=298.48s system=1245.37s cpu=614% total=4:11.40 Hence, I would suggest this isn't a bug but a design choice by Footnotes |
Thank you very much for looking into this!
Yes, I agree. In previous versions, Nevertheless, I think there are still two points worth addressing:
|
Checklist
man fzf
)Output of
fzf --version
0.55.0 (fc69308)
OS
Shell
Problem / Steps to reproduce
A simple call
fzf
in my home folder takes up all CPU and memory resources and seems to run forever. Initially, I assumed that my laptop is just too slow for fzf (see #4014), but now it looks more like a problem with an infinite loop of the fzf walker.I noticed that the issue disappears with
fzf --walker=file,hidden
(omittingfollow
). A subsequent investigation of all relevant subfolders which contain symlinks (withfind . -type l | sed 's/.\/\([^/]\+\).*/\1/p' | uniq
) showed a lot of wine prefixes.This suspicion indeed turned out to be the issue: The problem disappears with
fzf --walker-skip=drive_c,dosdevices
(two automatically created folders/symlinks in any wine prefix) and the walker finishes very quickly.As expected, the issue also disappears when disabling the internal walker and using
FZF_DEFAULT_COMMAND='find .' fzf
instead. When making find follow symlinksfind -L .
the command runs very long and there are lots of "Too many levels of symbolic links" and "File system loop detected" errors.I am a little surprised, though, that I should be the first one to report this issue, since wine is a widespread program? And the symlinks from wine won't be the only case that lead to infinite loops I guess? Interested to hear if others can reproduce the issue and how to deal with symlinks in general. 👍
The text was updated successfully, but these errors were encountered: