-
Notifications
You must be signed in to change notification settings - Fork 11
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
Throwing some errors (wrong number of arguments; nil value sList
)
#70
Comments
What was happening tho? Because your last commit was 2 months ago and this happened recently? |
Don't use lazy, I am not sure the issue existed before, but the code has a bug. |
What should be the loading event? Or should I do |
The bug should be gone for this issue. |
i still cannot use this i still get both Edit: i get a new Error executing vim.schedule lua callback: ...NeutronVim/lazy/hlchunk.nvim/lua/hlchunk/utils/cFunc.lua:47: wrong number of arguments for function call
stack traceback:
[C]: in function 'ml_get_buf'
...NeutronVim/lazy/hlchunk.nvim/lua/hlchunk/utils/cFunc.lua:47: in function 'get_line'
...tronVim/lazy/hlchunk.nvim/lua/hlchunk/utils/position.lua:21: in function 'get_char_at_pos'
...ronVim/lazy/hlchunk.nvim/lua/hlchunk/mods/chunk/init.lua:101: in function 'get_chunk_data'
...ronVim/lazy/hlchunk.nvim/lua/hlchunk/mods/chunk/init.lua:131: in function 'render'
...ronVim/lazy/hlchunk.nvim/lua/hlchunk/mods/chunk/init.lua:187: in function 'fn'
...NeutronVim/lazy/hlchunk.nvim/lua/hlchunk/utils/timer.lua:64: in function 'fn'
...NeutronVim/lazy/hlchunk.nvim/lua/hlchunk/utils/timer.lua:16: in function <...NeutronVim/lazy/hlchunk.nvim/lua/hlchunk/utils/timer.lua:15> |
with this config: {
"kevinhwang91/nvim-hlslens",
event = { "CmdlineEnter", "LazyFile" },
enabled = true,
keys = {
{
"n",
[[<cmd>execute('normal! ' . v:count1 . 'n')<cr>]] .. [[<cmd>lua require("hlslens").start()<cr>]],
},
{
"N",
[[<cmd>execute('normal! ' . v:count1 . 'N')<cr>]] .. [[<cmd>lua require("hlslens").start()<cr>]],
},
{ "*", "*" .. [[<cmd>lua require("hlslens").start()<cr>]] },
{ "#", "#" .. [[<cmd>lua require("hlslens").start()<cr>]] },
{ "g*", "g*" .. [[<cmd>lua require("hlslens").start()<cr>]] },
{ "g#", "g#" .. [[<cmd>lua require("hlslens").start()<cr>]] },
},
opts = {
override_lens = function(render, posList, nearest, idx, relIdx)
local sfw = vim.v.searchforward == 1
local indicator, text, chunks
local absRelIdx = math.abs(relIdx)
if absRelIdx > 1 then
indicator = ("%d%s"):format(absRelIdx, sfw ~= (relIdx > 1) and "▲" or "▼")
elseif absRelIdx == 1 then
indicator = sfw ~= (relIdx == 1) and "▲" or "▼"
else
indicator = ""
end
local lnum, col = unpack(posList[idx])
if nearest then
local cnt = #posList
if indicator ~= "" then
text = ("[%s %d/%d]"):format(indicator, idx, cnt)
else
text = ("[%d/%d]"):format(idx, cnt)
end
chunks = { { " " }, { text, "HlSearchLensNear" } }
else
text = ("[%s %d]"):format(indicator, idx)
chunks = { { " " }, { text, "HlSearchLens" } }
end
render.setVirt(0, lnum - 1, col - 1, chunks, nearest)
end,
},
config = true,
}, im only getting the above |
what's |
sorry thats another plugin but the name was similar 😞, tho this hasnt been fixed the first time its Error executing vim.schedule lua callback: ...NeutronVim/lazy/nvim-hlslens/lua/hlslens/render/init.lua:89: attempt to get length of field 'sList' (a nil value)
stack traceback:
...NeutronVim/lazy/nvim-hlslens/lua/hlslens/render/init.lua:89: in function 'refreshCurrentBuf'
...NeutronVim/lazy/nvim-hlslens/lua/hlslens/render/init.lua:424: in function ''
vim/_editor.lua: in function <vim/_editor.lua:0> |
maybe other plugins render |
I remember it seems like the information displayed by by the way, I can't reproduce this bug, Has it been fixed already? |
yes its fixed, oh was it noice, thanks for that |
this thing is fixed thanks buddy for ur time |
nvim --version
: 0.10.0Describe the bug
I'm getting some weirdo errors: (Doesnt happen of plugin load, only happens when we use the plugin explicitly)
First Error:
Second error (every time i call the plugin 2 times for each use)
To Reproduce using
nvim -u mini.lua
Steps to reproduce the behavior:
CmdLine
and/<search term>
orn
orN
Expected behavior
It should not throw any error
Screenshots

The text was updated successfully, but these errors were encountered: