Coc.nvim: closing floating window with a split window closes current window

Created on 16 Oct 2020  ·  3Comments  ·  Source: neoclide/coc.nvim

Result from CocInfo

## versions

vim version: NVIM v0.4.4
node version: v12.19.0
coc.nvim version: 0.0.79-80ae19dee6
coc.nvim directory: /Users/matthieu.arene/.local/share/nvim/plugged/coc.nvim
term: iTerm.app
platform: darwin

Describe the bug

When a split window (or a tab) is open, and a coc floating window pops up (for example when the cursor gets placed on a warning, or when the documentation of a symbol gets consulted), if the cursor is moved, then the current window is closed.
(see screenshot section for more clarity).

This baffles me because I had close to exactly the same nvim/coc setup on my previous work macbook three days ago, and it worked just fine: I possibly done a stupid configuration mistake, but I just cannot find it.

Reproduce the bug

  • Create file mini.vim with:

    set nocompatible
    set runtimepath^=/Users/matthieu.arene/.local/share/nvim/plugged/coc.nvim
    filetype plugin indent on
    syntax on
    set hidden
    call plug#begin(stdpath('data') . '/plugged')
    Plug 'neoclide/coc.nvim', {'branch': 'release'}
    call plug#end()
    
  • Start (neo)vim with command: vim -u mini.vim

  • Open a split window, in one of those windows navigate to a warning (or hover over a documented symbol). Once a floating window pops up, move the cursor and the current window will close

Screenshots

output

Most helpful comment

d4d93dc2 - fix(util): check winid for coc#util#close_win

All 3 comments

Fixed on latest release branch of coc.nvim.

Ah, I feel silly now, thanks a bunch!
Out of curiosity, what precise commit did fix this? I'm asking because I installed coc on the 15th (with Plug 'neoclide/coc.nvim', {'branch': 'release'}'), so I guess it was a recent one?

d4d93dc2 - fix(util): check winid for coc#util#close_win

Was this page helpful?
0 / 5 - 0 ratings

Related issues

cvlmtg picture cvlmtg  ·  3Comments

iago-lito picture iago-lito  ·  3Comments

czepluch picture czepluch  ·  3Comments

svenstaro picture svenstaro  ·  4Comments

aareman picture aareman  ·  3Comments