Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: improve callAtomic error logging (#1110)
* Add failing test for bug Neovim seems to be completely ignoring any changes made in insert mode, which is causing neovim's buffer to get out of sync with the version of the file in VSCode. * Change Neovim version check The issue with insert mode changes getting ignored is caused by nvim_buf_set_text not being recognized by an old Neovim version installed on my computer (somewhere around 0.5.0), so make this more obvious by reporting an error if there the Neovim version than the current minimum required version (which is 0.8.0 according to the readme). * Add better error reporting for callAtomic The previous bug caused by nvim_buf_set_text not existing on older Neovim could have been noticed if you saw the error messages returned by Neovim, which included an "Invalid method: nvim_buf_set_text" error. Make bugs like this easier to find in the future by correctly logging those Neovim-returned errors. Also silence errors due to nvim_win_close calls since there seem to be several errors mentioning an invalid window ID being passed to it and those errors are currently probably more annoying than helpful. * Run CI on minimum supported Neovim version Make bugs involving old Neovim versions more apparent by running CI on the oldest supported version, so that we don't accidentally end up relying on features introduced in later versions. * chore: tweaks --------- Co-authored-by: wongxy <xiyao.wong@foxmail.com>
- Loading branch information