Skip to content
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

Freezes since the latest update #172

Open
kantord opened this issue Jan 27, 2021 · 9 comments
Open

Freezes since the latest update #172

kantord opened this issue Jan 27, 2021 · 9 comments

Comments

@kantord
Copy link

kantord commented Jan 27, 2021

Since the latest update, the plugin freezes on the second search.

On the first search, everything works fine but if I do a second search without exiting vim, it freezes forever.

I'm on NVIM v0.4.4

@eugen0329
Copy link
Owner

eugen0329 commented Jan 27, 2021

Thanks for the report.

Could you try with the minimal vimrc please?

  1. Insert the following code into /tmp/vimrc:
if !filereadable('/tmp/vim/autoload/plug.vim')
  exe 'silent !mkdir -p /tmp/vim/autoload && curl -fLo /tmp/vim/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
endif
set runtimepath+=/tmp/vim
call plug#begin('/tmp/vim/bundle')
Plug 'eugen0329/vim-esearch'
call plug#end()
PlugInstall | q
filetype plugin indent on
  1. Run nvim as nvim -u /tmp/vimrc

My steps are:

  1. Press \\fa<enter>
  2. Press \\fb<enter> and enter the pattern again.

My result is no freezes encountered (yet).

UPD Also provide your os name and any hints about the size of expected results please. If you have matches in minified js or svg files, it can result in some freezes, as vim itself tends to be slow when rendering huge files, but they still should be relatively small, not permanent.

@kantord
Copy link
Author

kantord commented Jan 27, 2021

2021-01-27T18:26:10+01:00

@eugen0329
Copy link
Owner

Could you run this command in the console mkdir -p /tmp/vim/autoload && curl -fLo /tmp/vim/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim please?

@kantord
Copy link
Author

kantord commented Jan 27, 2021

Using this vimrc, it doesn't freeze

@eugen0329
Copy link
Owner

That's strange, as the last two commits affect only <c-c> click in the prompt and existing swap messages when writing.

Probably, the issue is with a vim plugin you use. You can try to binary search it by disabling plugins listed in :au WinEnter,WinLeave,BufWinEnter,BufWinLeave or I'll try you vimrc tomorrow.

@kantord
Copy link
Author

kantord commented Jan 27, 2021

It is because of this plugin: https://github.com/TaDaa/vimade

@eugen0329
Copy link
Owner

eugen0329 commented Jan 29, 2021

Can't reproduce with:

if !filereadable('/tmp/vim/autoload/plug.vim')
  exe 'silent !mkdir -p /tmp/vim/autoload && curl -fLo /tmp/vim/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
endif
set runtimepath+=/tmp/vim
call plug#begin('/tmp/vim/bundle')
Plug 'eugen0329/vim-esearch'
Plug 'TaDaa/vimade'
call plug#end()
PlugInstall | q
filetype plugin indent on

Also tried your config with these two plugins injected.

More ideas to reproduce:

  1. Try to inspect htop output to see whether any remote plugins or lsp providers are stuck. I encounter the similar deadlock when I write a regular file or switch a tab, so this is probably a neovim bug.
  2. Try to reproduce the bug on a different machine with a different os using your latest configs. You can use this Vagrantfile example to access it faster.
Vagrant.configure('2') do |config|
  config.vm.box = 'ubuntu/focal64'

  config.vm.provision 'shell', inline: '
    curl -LO https://github.com/neovim/neovim/releases/latest/download/nvim.appimage
    chmod u+x nvim.appimage
    mv nvim.appimage /usr/local/bin/nvim
  '
end

Also provide your :version output, g:esearch configs and your os version please.

@kantord
Copy link
Author

kantord commented Jan 30, 2021

Sorry, I don't have Vagrant and I don't know if I'll have time to set it up. But I did a little bit more of trial and error and now it looks like if I enable the vim-buffet extension (which has to do with tabs) then I can consistently re-produce it.

BTW here's the list of all changes to my dotfiles since I installed vim-esearch: https://github.com/kantord/perfect-arch-config/compare/7c802d0c7eada9d86af7dd0efeba5a4172fd9d7d...master#diff-87302fb5f87b2db92b62050c696feff05c177e37d6a805297579189dff0df95fR7

@eugen0329
Copy link
Owner

Here is the place in vim-buffet. It gets into an infinite loop when i run the search 3rd time.

It seems that it has nothing to do with the version of the plugin you use:

if !filereadable('/tmp/vim/autoload/plug.vim')
  exe '!mkdir -p /tmp/vim/autoload && curl -fLo /tmp/vim/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
endif
set runtimepath+=/tmp/vim
call plug#begin('/tmp/vim/bundle')
Plug 'eugen0329/vim-esearch', {'commit': '3409f596097b552aa367d2a85a6193ba49f15c1b'}
Plug 'bagrat/vim-buffet'
call plug#end()
PlugInstall | q
filetype plugin indent on

In case you don't have much time to communicate with the author, you can add let g:buffet_hidden_buffers = ["terminal", "quickfix", "nofile"] workaround configuration to your init.vim.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants