fish-shell / fish-shell Public
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
fish appears to hang on first startup #6295
Comments
I've discovered a way of reproducing this:
Now fish is sitting there doing... something... with no output and no input, eating 100% of one CPU core. pstree shows it has no subproesses. strace shows it doing weird lstat calls on files in my home directory
Note that ^C doesn't interrupt fish, I have to pkill it. |
I tried My ~/.bash_history has 25876 lines in it. fish managed to call open() on fish_history 13723 times in the first 16 seconds, before I killed it. (My bashrc sets HISTSIZE=50000 and HISTFILESIZE=50000.) |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
A workaround is to create an empty |
@mgedmin This commit might solve it: krobelus@speedup-bash-history-import, I was able to import 20k lines of history instantly. |
Fixed in master now. Thanks for your very useful report! You can remove your |
I can confirm that this fixes the entirety of the problem. Thank you! |
I've been meaning to try out fish on several occasions (years apart), but I always stumble upon this issue.
On my system (various versions of Ubuntu, currently 19.10) I do
and what happens next:
On second run fish starts instantly.
I'm not sure how to reset the state so this happens again.
fish version: 3.0.2
OS: Ubuntu 19.10
$TERM: xterm-256color
Terminal emulator: gnome-terminal 3.34.0 (VTE 0.58.2)
I cannot reproduce this with
sh -c 'env HOME=$(mktemp -d) fish'
! But if I try to close the shell I spawned that way, I get a warning about active jobs, which might be a Clue.(this also leaves my terminal in a noecho mode, which is annoying but unrelated)
It seems that something in my home directory (its sheer size? some config file somewhere?) is causing this, but I don't know what.
The text was updated successfully, but these errors were encountered: