-
Notifications
You must be signed in to change notification settings - Fork 33
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
Constant "attempt to concatenate a nil value error" #77
Comments
please try running
If that doesn't fix the problem, could you share more information about your machine? |
If you try this command, it should output what neovim thinks your system details are. $ nvim --headless '+lua =vim.inspect(vim.loop.os_uname())' '+qa' |
Inspecting the code, it seems that the |
Yes, in this case I'm running FreeBSD, but that doesn't justify spamming me with the above error to the point that neovim is unusable. Instead of constantly throwing this error, if the plugin detects the platform is unsupported then it should stop trying to load or error silently rather than having me hit |
Now to be fair, FreeBSD does has the ability to run Linux binaries, so it is possible the amd64 Linux binary could work (similar to using wine to run Windows programs on Unix-like OS) but that is a different matter. My use case isn't that uncommon, as I share all my configs across all my machines via a VCS repo (https://gitlab.com/vendion/dotfiles) which includes FreeBSD machines (amd64) and Linux (amd64, aarch64). |
To be clear, I'm not saying this is intended behavior, I was simply hypothesizing about the cause of the issue |
I wonder if just returning an empty string would even cause any issues... something like this: if os_uname.sysname == "Linux" and os_uname.machine == "x86_64" then
return "x86_64-unknown-linux-musl"
elseif
-- ...
else
return ""
end the binary would not be found, causing the Though in the long term, detecting unsupported configurations is a much better idea. |
This avoids constant nil errors (fixes codota#77), and quits early if the binary can't be found. Notifications can easily be added in future commits if so desired to warn the user about what is wrong.
This avoids constant nil errors (fixes codota#77), and quits early if the binary can't be found. Notifications can easily be added in future commits if so desired to warn the user about what is wrong.
This avoids constant nil errors (fixes codota#77), and quits early if the binary can't be found. Notifications can easily be added in future commits if so desired to warn the user about what is wrong.
This avoids constant nil errors (fixes codota#77), and quits early if the binary can't be found. Notifications can easily be added in future commits if so desired to warn the user about what is wrong.
This avoids constant nil errors (fixes codota#77), and quits early if the binary can't be found. Notifications can easily be added in future commits if so desired to warn the user about what is wrong.
same problem |
I had this exact problem while on an ARM linux machine (asahi fedora to be precise). The fix I made was more or less following the conversation thread here. I narrowed the nil value output down to the case statements in local function arch_and_platform()
local os_uname = uv.os_uname()
if os_uname.sysname == "Linux" and os_uname.machine == "x86_64" then
return "x86_64-unknown-linux-musl"
-- REDFLAME2112: Added this line to help support aarch64 linux...
elseif os_uname.sysname == "Linux" and os_uname.machine == "aarch64" then
return "aarch64-unknown-linux-gnu"
elseif os_uname.sysname == "Darwin" and os_uname.machine == "arm64" then
return "aarch64-apple-darwin"
elseif os_uname.sysname == "Darwin" then
return "x86_64-apple-darwin"
elseif os_uname.sysname == "Windows_NT" and os_uname.machine == "x86_64" then
return "x86_64-pc-windows-gnu"
elseif os_uname.sysname == "Windows_NT" then
return "i686-pc-windows-gnu"
end
end :) |
Tabnine now offers arm64 support.. is there anyone here who will be willing to test it? |
Yes, I would be interested in trying it. |
@vendion I'm unable to test it atm as I don't have an access to an arm machime, can you please test this? https://github.com/codota/tabnine-nvim/pull/179/files Appreciate your feedback! |
Merging this for now.. let me know if you have any issue |
With the latest version of tabnine-nvim I get the following error message whenever I open Neovim:
Worse is whenever I dismiss this error it comes back up a few seconds later.
The text was updated successfully, but these errors were encountered: