You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I :bdelete the scratch buffer, the BufUnload event fires and the callback receives the number of the newly focused buffer (i.e. the same as nvim.current.buffer, not the scratch buffer) in its buffer argument, from the <abuf> expansion.
IIUC, the BufUnload docs says <abuf> should hold the unloading buffer number (here, the scratch buffer). Am I doing something wrong or is that a bug?
Here a rpcrequest call should block until a response is received, and note that the evaluation of expand("<abuf>") is done on the neovim client side (in the vimscript that calls the autocmd).
But in the first invocation when it is yet to be bootstrapped:
It looks like by the time the actual RPC request is made, the buffer is already gone and hence wrong buffer number is passed. I think this is a bug of neovim core (rplugin provider) rather than pynvim --- probably why node-client also suffers the same error.
this executes doau RPC_DEFINE_AUTOCMD_GROUP_2 BufUnload (i.e. no <amatch>, <abuf>) -- <amatch>, <abuf> cannot be expanded correctly due to a different (autocmd) execution context (i.e. during doautocmd BufUnload).
When I
:bdelete
the scratch buffer, the BufUnload event fires and the callback receives the number of the newly focused buffer (i.e. the same asnvim.current.buffer
, not the scratch buffer) in itsbuffer
argument, from the<abuf>
expansion.IIUC, the BufUnload docs says
<abuf>
should hold the unloading buffer number (here, the scratch buffer). Am I doing something wrong or is that a bug?(This looks a lot like neovim/node-client#58.)
The text was updated successfully, but these errors were encountered: