Closed ghost closed 1 month ago
Upon some sniffing, it is probably because it pulls the precompiled toml-edit from here, perhaps a way to manually force plugins to be compiled, like the README says is done on some architectures would solve this
perhaps a way to manually force plugins to be compiled, like the README says is done on some architectures would solve this
Yep, that sounds like a good idea. We could also try to automate this based on the presence of the libraries.
As a workaround, you could follow the manual installation instructions without specifying the rocks-binaries server.
I worked around it by grabbing the installer script, and manually removing the server. After that, fzy failed to compile as it called gcc, which is not present (why not just call cc instead), to work around this, I ran
env CC=/usr/bin/clang LD=/usr/bin/ld.lld nvim -u NORC -c "source /home/<user>/installer.lua"
And the install worked. Can I set these envs for rocks.nvim somewhere?
There are however, still a few errors. Checking the logs for Rocks I see this error:
ERROR | 2024-05-19 11:27:42 | .../.local/share/nvim/rocks/share/lua/5.1/rocks/adapter.lua:53 | Failed to remove symlink: /home/<user>/.local/share/nvim/rocks/rocks_rtp/parser (ENOENT: no such file or directory: /home/<user>/.local/share/nvim/rocks/rocks_rtp/parser)
but rocks seems to work fine.
Another potentially related issue is with nvim-treesitter, I seem to be unable to install any parsers. I run :TSInstall <parser>
, but when running TSInstallInfo
, they are listed as not installed, moreover, some parsers, like lua, give the following error:
nvim-treesitter[lua]: Failed to execute the following command:
{
cmd = "mv",
opts = {
args = { "-f", "tree-sitter-lua-tmp/tree-sitter-lua-master", "tree-sitter-lua" },
cwd = "/home/<user>/.local/share/nvim",
stdio = {
[2] = <userdata 1>,
[3] = <userdata 2>
}
}
}
mv: rename tree-sitter-lua-tmp/tree-sitter-lua-master to tree-sitter-lua: No such file or directory
This setup is very hacky, but if you have any ideas, help would be appreciated.
Can I set these envs for rocks.nvim somewhere?
Not as of today. These are luarocks config variables. I have a draft PR to make it possible to override the luarocks config:
There are however, still a few errors. Checking the logs for Rocks I see this error:
The log message is harmless, but I've opened #345.
I seem to be unable to install any parsers. I run :TSInstall
, but when running TSInstallInfo, they are listed as not installed,
This is because nvim-treesitter uses a hack to determine where it is installed. This breaks with the way luarocks packages are installed. Also, the nvim-treesitter luarocks package is compatible with neovim 0.9.2, not 0.10.0.
You have a few options:
:Rocks install tree-sitter-{lang}
where {lang}
is the parser language) and set up highlighting manually with vim.treesitter.start()
See also: https://github.com/nvim-neorocks/rocks.nvim/#deciduous_tree-enhanced-tree-sitter-support
Thanks, got rocks set all up now, seems like the CC and LD variable for luarocks works just fine. Sorry for filling this issue with unrelated questions
Hey, I am receiving a similar type of error with rocks.nvim (on ArchWSL)
Error executing vim.schedule lua callback: ...arun/.local/share/nvim/rocks/share/lua/5.1/nio/tasks.lua:100: Async task failed without callback: The coroutine failed with th
is message:
...tarun/.local/share/nvim/rocks/share/lua/5.1/nio/init.lua:119: The coroutine failed with this message: Task was cancelled
stack traceback:
[C]: in function 'error'
...tarun/.local/share/nvim/rocks/share/lua/5.1/nio/init.lua:119: in function 'gather'
.../luarocks/rocks-5.1/rocks.nvim/2.30.0-1/plugin/rocks.lua:46: in function <.../luarocks/rocks-5.1/rocks.nvim/2.30.0-1/plugin/rocks.lua:44>
stack traceback:
[C]: in function 'error'
...arun/.local/share/nvim/rocks/share/lua/5.1/nio/tasks.lua:100: in function 'close_task'
...arun/.local/share/nvim/rocks/share/lua/5.1/nio/tasks.lua:122: in function 'cb'
...arun/.local/share/nvim/rocks/share/lua/5.1/nio/tasks.lua:188: in function 'waiter'
...un/.local/share/nvim/rocks/share/lua/5.1/nio/control.lua:57: in function 'set'
...tarun/.local/share/nvim/rocks/share/lua/5.1/nio/init.lua:105: in function 'cb'
...arun/.local/share/nvim/rocks/share/lua/5.1/nio/tasks.lua:98: in function 'close_task'
...arun/.local/share/nvim/rocks/share/lua/5.1/nio/tasks.lua:122: in function 'cb'
...arun/.local/share/nvim/rocks/share/lua/5.1/nio/tasks.lua:188: in function 'waiter'
...un/.local/share/nvim/rocks/share/lua/5.1/nio/control.lua:116: in function 'wake'
...un/.local/share/nvim/rocks/share/lua/5.1/nio/control.lua:137: in function 'set_error'
...un/.local/share/nvim/rocks/rocks_rtp/lua/rocks/state.lua:37: in function 'on_exit'
....local/share/nvim/rocks/rocks_rtp/lua/rocks/luarocks.lua:68: in function ''
vim/_editor.lua: in function <vim/_editor.lua:0>
@TarunDaCoder that's a different error, unrelated to this issue.
Are you able to reproduce it with the latest rocks.nvim version?
If so, could you please open a separate issue and include your :Rocks log
?
@TarunDaCoder You're probably running into https://github.com/nvim-neorocks/rocks.nvim/issues/377
I'll look into it later today.
On Linux distributions without libgcc, such as Chimera Linux which uses libunwind instead, nvim spits the following error when opening nvim.
It seems might be an issue with the toml-edit dependency, but I am unsure. Is there anything that can be done? Or is the issue with luarocks linking libgcc?