Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Attempt to perform arithmetic on field 'zindex' (a nil value) in scrollbar #129

Closed
lostl1ght opened this issue Oct 26, 2022 · 1 comment · Fixed by #639
Closed

Attempt to perform arithmetic on field 'zindex' (a nil value) in scrollbar #129

lostl1ght opened this issue Oct 26, 2022 · 1 comment · Fixed by #639
Labels
bug Something isn't working

Comments

@lostl1ght
Copy link

Describe the bug
Something about attempting to perform arithmetic on a nil value whenever a notification has multiple lines.

Which version of Neovim are you using?
Latest nightly

To Reproduce
Steps to reproduce the behavior:

  1. Open cmdline and type lua =vim.loop or version, press enter
  2. Open cmdline and type Noice, press enter
  3. Attempt to scroll the window with arrows or jk
  4. Observe an error notification on every key press

Expected Behavior
An error should not appear.

Noice Log

Noice log
...ack/packer/start/noice.nvim/lua/noice/view/scrollbar.lua:112: attempt to perform arithmetic on field 'zindex' (a nil value)

stack traceback:
[C]: in function 'pcall'
...ite/pack/packer/start/noice.nvim/lua/noice/util/call.lua:140: in function '__add'
...ack/packer/start/noice.nvim/lua/noice/view/scrollbar.lua:112: in function 'update'
...ack/packer/start/noice.nvim/lua/noice/view/scrollbar.lua:64: in function 'show'
...site/pack/packer/start/noice.nvim/lua/noice/view/nui.lua:224: in function <...site/pack/packer/start/noice.nvim/lua/noice/view/nui.lua:197>
[C]: in function 'xpcall'
...ite/pack/packer/start/noice.nvim/lua/noice/util/call.lua:145: in function 'try'
...ite/pack/packer/start/noice.nvim/lua/noice/view/init.lua:123: in function 'display'
...site/pack/packer/start/noice.nvim/lua/noice/commands.lua:48: in function 'history'
...site/pack/packer/start/noice.nvim/lua/noice/commands.lua:61: in function <...site/pack/packer/start/noice.nvim/lua/noice/commands.lua:56>

Mini Config

Config
vim.cmd([[packadd packer.nvim]])

return require('packer').startup(function(use)
  use('wbthomason/packer.nvim')
  use({
    'folke/noice.nvim',
    config = function()
      require('noice').setup()
    end,
    requires = {
      'MunifTanjim/nui.nvim',
    },
  })
end)
@lostl1ght lostl1ght added the bug Something isn't working label Oct 26, 2022
@folke folke closed this as completed in 07465b3 Oct 26, 2022
@lostl1ght
Copy link
Author

The bug is gone. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant