pretty-fold.nvim icon indicating copy to clipboard operation
pretty-fold.nvim copied to clipboard

Default binding for `h` and `l` causes non-responsive `PackerSync`

Open axieax opened this issue 2 years ago • 4 comments

Hi, it seems that the default keybinding for h and l (from pretty-fold.preview) causes the floating window for PackerSync (packer.nvim) to be non-responsive. j and k work fine however.

It seems like this causes an infinite loop in M.mapping.close_preview_open_fold(original), where original() causes this to be recursively called.

axieax avatar May 08 '22 06:05 axieax

It took me so long to find this, I had no idea at first it was the l or h keys that were causing this or a mapping at all. I just saw 100% cpu usage and nvim hanging. I tried profiling with :profile start but that doesn't work for lua stuff it seems, so I thought it was nvim itself at first. Sometimes it wouldn't happen for a day, sometimes every few minutes. Pretty sure it also happens for other filetypes/windows. At least I'm glad I found it now, after a few weeks of this, it was driving me crazy. Even a would not help every time, take many seconds to respond or even not at all, making me have to force close nvim and more than one time I borked the use of swapfiles and lost some work because of this.. smh

Frydac avatar May 27 '22 08:05 Frydac

Tried to fix this issue. Notify me if it happens again.

anuvyklack avatar Jun 29 '22 16:06 anuvyklack

No, it's still there.

anuvyklack avatar Jun 29 '22 21:06 anuvyklack

Should be fixed now.

anuvyklack avatar Jul 11 '22 16:07 anuvyklack