Shougo / denite.nvim

:dragon: Dark powered asynchronous unite all interfaces for Neovim/Vim8
Other
2.06k stars 215 forks source link

RecursionError when doing :Denite file/rec several times #516

Closed gauteh closed 6 years ago

gauteh commented 6 years ago

Warning: I will close the issue without the minimal init.vim and the reproduction instructions.

Problems summary

I am getting a crash when doing :Denite file/rec. Usually not the first time, and it seems to sometimes be related to having opened a split window.. Either way -- this might be a recursive function thing. The full log is attached, but below is the relevant traceback extracted:

[denite] Traceback (most recent call last):
[denite]   File "<string>", line 9, in _temporary_scope
[denite]   File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/ui/default.py", line 71, in start
[denite]     self._start(context['sources_queue'][0], context)
[denite]   File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/ui/default.py", line 127, in _start
[denite]     self.init_buffer()
[denite]   File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/ui/default.py", line 151, in init_buffer
[denite]     self._prev_wininfo = self._get_wininfo()
[denite]   File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/ui/default.py", line 247, in _get_wininfo
[denite]     wininfo = self._vim.call('getwininfo', self._vim.call('win_getid'))[0]
[denite]   File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 62, in call
[denite]     return reform_bytes(self.Function(name)(*args))
[denite]   File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 18, in reform_bytes
[denite]     return list(map(reform_bytes, value))
[denite]   File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 15, in reform_bytes
[denite]     reform_bytes(k): reform_bytes(v) for k, v in value.items()
[denite]   File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 15, in <dictcomp>
[denite]     reform_bytes(k): reform_bytes(v) for k, v in value.items()
[denite]   File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 15, in reform_bytes
[denite]     reform_bytes(k): reform_bytes(v) for k, v in value.items()
[denite]   File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 15, in <dictcomp>
[denite]     reform_bytes(k): reform_bytes(v) for k, v in value.items()
[denite]   File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 15, in reform_bytes
.....
Repeated loads and loads of times.. see full log attached.
.....
    reform_bytes(k): reform_bytes(v) for k, v in value.items()
  File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 15, in <dictcomp>
    reform_bytes(k): reform_bytes(v) for k, v in value.items()
  File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 15, in reform_bytes
    reform_bytes(k): reform_bytes(v) for k, v in value.items()
  File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 15, in <dictcomp>
    reform_bytes(k): reform_bytes(v) for k, v in value.items()
  File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 15, in reform_bytes
    reform_bytes(k): reform_bytes(v) for k, v in value.items()
  File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 15, in <dictcomp>
    reform_bytes(k): reform_bytes(v) for k, v in value.items()
  File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 18, in reform_bytes
    return list(map(reform_bytes, value))
  File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 13, in reform_bytes
    elif isinstance(value, (dict, vim.Dictionary, vim.Options)):
RecursionError: maximum recursion depth exceeded in __instancecheck__

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<string>", line 16, in <module>
  File "<string>", line 14, in _temporary_scope
  File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/util.py", line 45, in error
    vim.call('denite#util#print_error', string)
  File "/home/gaute/dev/misc/dotfiles/vim/.vim/plugged/denite.nvim/rplugin/python3/denite/rplugin.py", line 62, in call
    return reform_bytes(self.Function(name)(*args))
KeyboardInterrupt

Expected

Environment Information (Required!)



 * `:checkhealth` or `:CheckHealth` result(neovim only):

## Provide a minimal init.vim with less than 50 lines (Required!)
.....

## How to reproduce problems from neovim startup (Required!)

Doesn't always happen, but stress testing `:Denite file/rec` in my .vim folder with a few files open seems to do the trick.

## Generate a logfile if appropriate

 1. vim -Vlog.vim
[vimlog.txt](https://github.com/Shougo/denite.nvim/files/2260109/vimlog.txt)

## Upload the log file
Shougo commented 6 years ago

Your Vim version is old. Please use the latest version.

I think it is not reproduced in neovim.

Shougo commented 6 years ago

Doesn't always happen, but stress testing :Denite file/rec in my .vim folder with a few files open seems to do the trick.

I cannot reproduce the problem. Please describe the reproduce instructions more clearly.

If you don't provide it, I will close the issue unfortunately.

gauteh commented 6 years ago

Shougo writes on August 6, 2018 4:41:

Your Vim version is old. Please use the latest version.

I do not think it is very old (released this May), its the latest available in Arch Linux.

I think it is not reproduced in neovim.

Have not tried. But it is supposed to work on Vim 8 as well?

I haven't been able to reliably reproduce the issue, but it happens often enough that I cannot use it. I understand if you close the issue, but unfortunately this makes the plugin unusable for me.

Shougo commented 6 years ago

I do not think it is very old (released this May), its the latest available in Arch Linux.

It is old. Because, 8.1.240 is already released. https://github.com/vim/vim/commit/3cb4448b8a5c0192988f4e349aba6d7a91a9a4bd

But it is supposed to work on Vim 8 as well?

It works, but it uses compatible plugin(rplugin.py). It may have problems. neovim is better.

I haven't been able to reliably reproduce the issue, but it happens often enough that I cannot use it. I understand if you close the issue, but unfortunately this makes the plugin unusable for me.

Of course, I understand. But to fix the problem, denite must use nvim-yarp instead. It adds the another dependency. So I don't want to do it.

Shougo commented 6 years ago

Please built Vim8.1 HEAD manually. I don't recommend for you to use ArchLinux released version. It is very old for me.

gauteh commented 6 years ago

Ok, that is not an option for me unfortunately since I need my vim setup to work on several machines. Some of them on slightly older systems where I do not have the possibility to run the latest vim. Was this fixed in 27ffda7? Otherwise, I understand your decision.

Shougo commented 6 years ago

Was this fixed in 27ffda7?

Yes.