Closed Rolv-Apneseth closed 4 weeks ago
Thanks It looks like a bug in treesitter, but I added a fix here so it doesn't freeze Neovim.
Ah I see, do you think I should open an issue there then? Thank you for the workaround though!
Hello! I get the same error on version 3.8.3 (nvim 0.10.2). Configuration
{
"lukas-reineke/indent-blankline.nvim",
main = "ibl",
---@module "ibl"
---@type ibl.config
opts = {},
-- tag = "v3.7.2",
},
I don’t run this code: require("ibl").setup()
, because errors appear even before it. If I turn on setup, the theme I installed crashes and there are more errors.
Errors:
Failed to run `config` for indent-blankline.nvim
...e/nvim/lazy/indent-blankline.nvim/lua/ibl/highlights.lua:95: No highlight group 'IblScope' found
# stacktrace:
- /indent-blankline.nvim/lua/ibl/highlights.lua:95 _in_ **setup**
- /indent-blankline.nvim/lua/ibl/init.lua:41 _in_ **setup**
- /indent-blankline.nvim/lua/ibl/init.lua:57 _in_ **setup**
- ~/.config/nvim/lua/core/plugins.lua:20
- ~/.config/nvim/init.lua:4
Error executing vim.schedule lua callback: ...l/share/nvim/lazy/indent-blankline.nvim/lua/ibl/init.lua:152: Tried to refresh withou
t doing setup
stack traceback:
[C]: in function 'assert'
...l/share/nvim/lazy/indent-blankline.nvim/lua/ibl/init.lua:152: in function 'refresh'
...l/share/nvim/lazy/indent-blankline.nvim/lua/ibl/init.lua:127: in function 'debounced_refresh'
...l/share/nvim/lazy/indent-blankline.nvim/lua/ibl/init.lua:143: in function 'debounced_refresh'
.../nvim/lazy/indent-blankline.nvim/lua/ibl/inlay_hints.lua:51: in function 'handler'
...im.aWFsfp1/usr/share/nvim/runtime/lua/vim/lsp/client.lua:687: in function ''
vim/_editor.lua: in function <vim/_editor.lua:0>
Problem
I'm having a very specific bug from what I can tell, though I have been able to get a minimal reproducible example. When deleting certain lines in a Rust file, neovim will freeze the terminal completely and ramp up CPU usage. It seems to be some interaction between this plugin and treesitter, and disabling either of them fixes the issue.
I have also tried other versions of this plugin, all the way to v3.0.0 and the same issue is there so it doesn't seem to be a recent regression. I have had freezes in the past but this was just the first time I chose to dig into it.
Hope this is enough info, but let me know if you need more. Also happy to test stuff if needed.
Steps to reproduce
Run:
Then delete lines 7 and 8 (the ones inside the
Command
struct) at the same time (dj
,dk
,di{
, etc.) and the program freezes.minimal.lua
main.rs
Expected behavior
Shouldn't freeze.
Neovim version (nvim -v)
v0.10.2