m00qek / baleia.nvim

Colorize text with ANSI escape sequences (8, 16, 256 or TrueColor)
138 stars 5 forks source link

Expected Lua number in function 'is_empty' on latest Neovim #5

Closed daveyarwood closed 2 years ago

daveyarwood commented 2 years ago

After updating Neovim this morning (I use the unstable branch), I get this error every time I open a Clojure buffer:

Error executing vim.schedule lua callback: .../dave/.vim/bundle/baleia.nvim/lua/baleia/nvim/buffer.lua:99: Expected Lua number                                                
stack traceback:                                                                                                                                                              
        [C]: in function 'nvim_buf_line_count'                                                                                                                                
        .../dave/.vim/bundle/baleia.nvim/lua/baleia/nvim/buffer.lua:99: in function 'is_empty'                                                                                
        /home/dave/.vim/bundle/baleia.nvim/lua/baleia.lua:53: in function </home/dave/.vim/bundle/baleia.nvim/lua/baleia.lua:52>    

I'm guessing this is related to colorizing the Conjure log buffer, which is why this is only happening when opening a Clojure buffer.

I followed the instructions in the README in an attempt to get logs, but when I ran :BaleiaLogs, I got this error:

E121: Undefined variable: g:baleia  
m00qek commented 2 years ago

Thank for reporting this. Fixed by https://github.com/m00qek/baleia.nvim/commit/50a068ffd3c1eef1d3ae827b221d367db629c96e

daveyarwood commented 2 years ago

Awesome, thanks! 🎉