mg979 / vim-visual-multi

Multiple cursors plugin for vim/neovim
MIT License
4.24k stars 82 forks source link

ctrl-n with vim-visual-multi crashes vim #255

Open robacarp opened 9 months ago

robacarp commented 9 months ago

Thank you for this plugin. I use it daily and I find it bridges a gap in a few places in core vim that I simply have no other way to get to quickly.

Describe the issue:

Sometimes, tapping ctrl-n to invoke vim-visual-multi causes macvim to crash. Frustratingly, it's not every time.

This has been happening through multiple versions of macvim, vim-visual-multi, and the other plugins I run. Generally speaking it's not frequent enough that it causes problems, but lately it has increased. I didn't see anything in the github issues, and I haven't for months, so I have to assume the problem is a result of some combination of plugins. I confess I have no idea how to write a better bug report.

I will use the minimal vimrc embedded in the issue template and attempt to reproduce. I'm not particularly hopeful I'll find a known cause. The interruption to my workflow has been incredibly frustrating lately, and my main reason for opening the issue here is, if anyone else is hitting this, we can work together to find information.

I'm not an advanced vim scripter by any means, so perhaps there's some log file I can go get after it crashes. I have no idea.

Steps to reproduce

This is not guaranteed, but I'm aware that it's more likely to happen when I attempt to activate multiple cursors on a single character word.


mg979 commented 9 months ago

It crashes the first time you press ctrl-n after entering vim, or in other occasions too?

robacarp commented 9 months ago

Not necessarily the first time activating with ctrl-n. It can happen at any time.

mg979 commented 9 months ago

I think it is specific to MacVim or mac, I don't have a way to investigate. But I don't think it has to do with vimscript, maybe with clipboard, this plugin doesn't write to system clipboard, maybe something is forcing to use the system clipboard? Try to do ctrl-n and see the output of :set clipboard (while still inside VM, don't exit), to see if the setting isn't an empty string (as it should).