Stack trace on each kulala.nvim UI window close
14:23:50 msg_show.lua_print ....local/share/nvim/lazy/ui/lua/nvchad/tabufline/utils.lua:38: Invalid buffer id: 240
stack traceback:
[C]: in function 'buf_name'
....local/share/nvim/lazy/ui/lua/nvchad/tabufline/utils.lua:38: in function 'gen_unique_name'
....local/share/nvim/lazy/ui/lua/nvchad/tabufline/utils.lua:53: in function 'style_buf'
...ocal/share/nvim/lazy/ui/lua/nvchad/tabufline/modules.lua:80: in function <...ocal/share/nvim/lazy/ui/lua/nvchad/tabufline/modules.lua:66>
...ocal/share/nvim/lazy/ui/lua/nvchad/tabufline/modules.lua:123: in function <...ocal/share/nvim/lazy/ui/lua/nvchad/tabufline/modules.lua:113>
[C]: at 0x0102f82a78
[C]: in function 'pcall'
.../share/nvim/lazy/nvim-notify/lua/notify/windows/init.lua:321: in function '_advance_win_state'
.../share/nvim/lazy/nvim-notify/lua/notify/windows/init.lua:181: in function '_update_window'
.../share/nvim/lazy/nvim-notify/lua/notify/windows/init.lua:37: in function <.../share/nvim/lazy/nvim-notify/lua/notify/windows/init.lua:30>
[C]: in function 'pcall'
...
[C]: in function 'xpcall'
...local/share/nvim/lazy/noice.nvim/lua/noice/util/call.lua:149: in function <...local/share/nvim/lazy/noice.nvim/lua/noice/util/call.lua:134>
...local/share/nvim/lazy/noice.nvim/lua/noice/view/init.lua:170: in function 'display'
.../share/nvim/lazy/noice.nvim/lua/noice/message/router.lua:214: in function <.../share/nvim/lazy/noice.nvim/lua/noice/message/router.lua:147>
[C]: in function 'xpcall'
...local/share/nvim/lazy/noice.nvim/lua/noice/util/call.lua:149: in function <...local/share/nvim/lazy/noice.nvim/lua/noice/util/call.lua:134>
[C]: in function 'pcall'
...local/share/nvim/lazy/noice.nvim/lua/noice/util/init.lua:146: in function ''
vim/_editor.lua: in function ''
vim/_editor.lua: in function <vim/_editor.lua:0>
What happens? kulala.nvim has a UI window which can be closed once done with it. Each time I close it, I get the above stack trace and the tabufline breaks completely.
I am closing the window using the plugin's built-in keymap 'q', so it is not like I am closing this window in any improper way.
Neovim version:
NVIM v0.11.0-dev-1684+g0c8890e7a7
Build type: RelWithDebInfo
LuaJIT 2.1.1736781742
can you show a video?
and your settings for that plugin
@siduck Please find the requested information below.
https://github.com/user-attachments/assets/8cb22927-1b67-45f7-ae11-49f5ec8296f6
I disabled noice.nvim just to eliminate it from the picture. Here is the new stack trace:
Errors in request localhost:8081/test at line: 2
* Host localhost:8081 was resolved.
....local/share/nvim/lazy/ui/lua/nvchad/tabufline/utils.lua:38: Invalid buffer id: 10
stack traceback:
[C]: in function 'buf_name'
....local/share/nvim/lazy/ui/lua/nvchad/tabufline/utils.lua:38: in function 'gen_unique_name'
....local/share/nvim/lazy/ui/lua/nvchad/tabufline/utils.lua:53: in function 'style_buf'
...ocal/share/nvim/lazy/ui/lua/nvchad/tabufline/modules.lua:80: in function <...ocal/share/nvim/lazy/ui/lua/nvchad/tabufline/modules.lua:66>
...ocal/share/nvim/lazy/ui/lua/nvchad/tabufline/modules.lua:123: in function <...ocal/share/nvim/lazy/ui/lua/nvchad/tabufline/modules.lua:113>
E15: Invalid expression: "v:lua.require('nvchad.tabufline.modules')()"
Errors in request localhost:8081/test at line: 2
* Host localhost:8081 was resolved.
Plugin settings:
{
"mistweaverco/kulala.nvim",
opts = {
default_view = "headers_body",
},
},
i will test it tomorrow 👍
Thank you very much 🙂
vim.api.nvim_create_autocmd("BufAdd" , {
callback = function(args)
vim.print{args.buf, vim.bo[args.buf].ft}
end,
})
@mistweaverco do you use eventignore for your plugin? i dont see it at bufdelete event, weird
Here is the new stack trace:
@daniel-odrinski Could you please update the ui plugin to the latest version and try the same thing again?
I have recently fixed a similar issue(#442), so so it is possible that the problem has already been resolved.
@glmlm its not related to that
{
"mistweaverco/kulala.nvim",
lazy = false,
opts = {},
}
and then run
:lua require("kulala").open()
and go to that window, press q
@glmlm Can confirm that your fix does not fix this issue.
@siduck @daniel-odrinski It appears that the issue is due to the buffer number nr of kulala.nvim being left in the vim.t.bufs. I'm investigating the cause little by little, but I'm afraid I cannot help you at the moment.
Thank you so much for your help @glmlm @siduck
@daniel-odrinski Could you please test my PR? This might solve the issue.
@siduck If you wouldn't mind confirming that this implementation is correct, I would be very grateful. I must admit that I have not read all of the code, so I am not sure if this is appropriate.
Will do @glmlm thanks :)
@siduck @daniel-odrinski It appears that the issue is due to the buffer number
nrof kulala.nvim being left in thevim.t.bufs. I'm investigating the cause little by little, but I'm afraid I cannot help you at the moment.
i know, the bufdelete even handler must remove it but idk how it ignores
@glmlm @siduck I am happy to report that this fix works :) Thank you so much!
dont close yet, i'll come back to this issue in few weeks and merge the code to main branch