bufferline.nvim icon indicating copy to clipboard operation
bufferline.nvim copied to clipboard

[Bug]: error showing bad arguments #1 to 'ipairs'.

Open AnirudhG07 opened this issue 1 year ago • 3 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

What happened?

I am running neovim v0.10.1 I am getting this error 60-70% of times when i run nvim ., (basically open neovim).

Error detected while processing BufEnter Autocommands for "*":
Error executing lua callback: ...re/nvim/lazy/bufferline.nvim/lua/bufferline/commands.lua:134: bad argument #1 to 'ipairs' (table expected, got nil)
stack traceback:
        [C]: in function 'ipairs'
        ...re/nvim/lazy/bufferline.nvim/lua/bufferline/commands.lua:134: in function 'get_current_element_index'
        ...hare/nvim/lazy/bufferline.nvim/lua/bufferline/groups.lua:491: in function 'handle_group_enter'
        ...local/share/nvim/lazy/bufferline.nvim/lua/bufferline.lua:141: in function <...local/share/nvim/lazy/bufferline.nvim/lua/bufferline.lua:141>
Press ENTER or type command to continue

A similar issue was posted previously, but it had no solutions for it. How to fix this issue?

What did you expect to happen?

Opens smoothly like usually

Config

Here is my dotfiles link, if someone needs to check whats going on.

Additional Information

When i try to do :Lazy, an empty box appears whenever the errors appears before entering nvim, whenever this error does not appear, then lazy appears smoothly. Thus everything is up to date from the Lazy side atleast.

commit

No response

AnirudhG07 avatar Aug 15 '24 14:08 AnirudhG07

Any solutions to this issue?

AnirudhG07 avatar Aug 18 '24 13:08 AnirudhG07

Same issue here. It started to appear when I upgraded from Nvim 0.9 to Nvim 0.10. I don't know if it's related to some kind of change from Nvim.

jpradass avatar Aug 20 '24 09:08 jpradass

@akinsho Please share some solution. This issue is really annoying.

AnirudhG07 avatar Aug 21 '24 19:08 AnirudhG07

@AnirudhG07 I can't reproduce this locally, I open nvim in version 0.10.1 with nvim . and nothing like you describe happens. I need a minimal reproducible setup WITHOUT your whole config just bufferline I have extremely limited time so will definitely not be digging through your config to isolate the issue. If you can find a minimal reproduction we can go from there.

akinsho avatar Aug 27 '24 13:08 akinsho

Thanks for the response. It's fine now. It automatically got fixed. I am closing this issue. Thanks for the cool plugin by the way!

AnirudhG07 avatar Sep 02 '24 13:09 AnirudhG07