Closed cmon1701 closed 2 months ago
I'm getting this same crash, to help with reproduction here's a minimal config:
And here's my steps to reproduce:
nvim -nu minimal.lua test.kt
:q
out of the lazy.nvim menu"test"
I find that nvim crashes when you type the e
And running on an M2 MacBook Air
Hope this helps :)
Thank you, @Akeboshiwind! Now I have a sensible minimal.lua for a lot of things :-) Your minimal.lua also causes crashes on my computer. For me, a lot of letters cause the crash.
Same here, I'm using the markdown
and markdown-inline
parsers. Typing the e
letter within a string crashes Neovim with the following errors:
Process 16085 (nvim) of user 1000 dumped core.
Stack trace of thread 16085:
#0 0x000071c88d61e5b0 n/a (/home/xxxx/.local/share/nvim/lazy/nvim-treesitter/parser/kotlin.so + 0x1e5b0)
#1 0x000071c88e8613ee ts_parser_parse (libtree-sitter.so.0 + 0xe3ee)
#2 0x000065435d1d8cc5 n/a (nvim + 0x243cc5)
#3 0x000071c88e7b8ef6 n/a (libluajit-5.1.so.2 + 0x6ef6)
#4 0x000071c88e7ccbea lua_pcall (libluajit-5.1.so.2 + 0x1abea)
#5 0x000065435d3ff9ee n/a (nvim + 0x46a9ee)
#6 0x000065435d4099d1 n/a (nvim + 0x4749d1)
#7 0x000065435d06ebcb decor_providers_invoke_win (nvim + 0xd9bcb)
#8 0x000065435d08ff72 n/a (nvim + 0xfaf72)
#9 0x000065435d08b9f6 update_screen (nvim + 0xf69f6)
#10 0x000065435d09ff7d n/a (nvim + 0x10af7d)
#11 0x000065435d095c6e n/a (nvim + 0x100c6e)
#12 0x000065435d342c33 state_enter (nvim + 0x3adc33)
#13 0x000065435d3fa155 n/a (nvim + 0x465155)
#14 0x000065435d2543f0 n/a (nvim + 0x2bf3f0)
#15 0x000065435d248b67 n/a (nvim + 0x2b3b67)
#16 0x000065435d342d2d state_enter (nvim + 0x3add2d)
#17 0x000065435d245d2a normal_enter (nvim + 0x2b0d2a)
#18 0x000065435cfdfb27 main (nvim + 0x4ab27)
#19 0x000071c88e495e08 n/a (libc.so.6 + 0x25e08)
#20 0x000071c88e495ecc __libc_start_main (libc.so.6 + 0x25ecc)
#21 0x000065435cfe1655 _start (nvim + 0x4c655)
Stack trace of thread 16087:
#0 0x0000000000000000 n/a (n/a + 0x0)
ELF object binary architecture: AMD x86-64
Here is the markdown codeblock:
fun main() {
println("He")
}
@cmon1701 I can't take credit, it's from the telescope repo :)
Also to be clear it's not just the letter e, but the second letter typed.
You can do the following:
echo '"t' > test.kt
nvim -nu minimal.lua test.kt
Interestingly you can keep entering things at the beginning of the string 🤷
I can confirm that this fixes it for me 👍
I can confirm this, too. Thank you! I wonder why nobody else noticed that before, is Kotlin used so rarely?
When I edit a simple Kotlin file (the one that is generated via gradle init) and Treesitter is active, Neovim frequently crashes. After :TSUninstall kotlin, Neovim does not crash, so it is a Treesitter kotlin issue.
This solution did not help: https://github.com/fwcd/tree-sitter-kotlin/issues/57 After TSInstall kotlin, Neovim crashes again.