You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug: Unable to install with nvchad. Cannot find package "lombok-nightly" #349
I have searched the existing issues of plugins related to this issue
Neovim version (nvim -v)
v0.10.4
Operating system/version
MacOS 15.0.1
Describe the bug
Not sure if this is a bug or just missing something in configuration. I am using NvChad as my base setup. I followed the instructions and always end up with this error:
mason tells you that it failed to download jdtls tarball from eclipse of. downloads portal. maybe it causes problems with lombok
i have the same issue with jdtls
Yeah I'm able to download and setup jdtls without nvim-java which led me to believe something else is going on. I haven't looked at the plugin's code yet.
How i tested jdtls on it's own:
Add jdtls to the ensure_installed for mason. and then set up the lsp config:
If you are using nvchad, their implementation might be the problem.
I cannot check this now but I'm guessing if a function is passed to opts then previous opts that comes as the second parameter should be merged. In not 100% though. Something like below
opts=function(_, prev_opts)
return merge(prev_opts, custom_opts)
end
If you are using nvchad, their implementation might be the problem.
Interesting. I have Mason defined in my own init lua which i believe overrides what they do. I'll check that.
on another note, writing the registry manually seems to have solved the installation issue. Installation completed but i'm not getting anything(like autocomplete) when i open a java file. Also, everytime i open a new file, mason starts trying to install spring-boot-tools and update java-test
Well, you should let it install. Nvim-java will not proceed unless there are all the required packages are installe. Nvchad replaced nvim java config and you override nvchad config. I'm closing the ticket since this looks like an issue in the distribution
Well, you should let it install. Nvim-java will not proceed unless there are all the required packages are installe. Nvchad replaced nvim java config and you override nvchad config. I'm closing the ticket since this looks like an issue in the distribution
I did let it finish but getting nothing in java files. Somehow nvim-java is not starting jdtls cause manually installing jdtls lsp give me autocomplete at least.
Nvim java does not start the language server. That's for you to do. What this plugin does is setting up packages for you to start jdtls using lspconfig. That's clearly mentioned in the readme
which i assumed meant it did all the ls stuff too.
I just added it back to my mason ensure_installed and started it. Everything seems to work fine now! Wow that was quite the ride. Thanks for the assist, much appreciated
Following fixes the mason registry issue. Please try updating nvim-java and see if everything works with manually adding the nvim-java mason registry #355
Following fixes the mason registry issue. Please try updating nvim-java and see if everything works with manually adding the nvim-java mason registry #355
Activity
YSNBx commentedon Feb 10, 2025
Any workarounds? Getting the same issue and I haven't managed to circumvent this issue.
rssnk commentedon Feb 10, 2025
mason tells you that it failed to download jdtls tarball from eclipse of. downloads portal. maybe it causes problems with lombok
i have the same issue with jdtls
fayimora commentedon Feb 10, 2025
Yeah I'm able to download and setup jdtls without nvim-java which led me to believe something else is going on. I haven't looked at the plugin's code yet.
How i tested jdtls on it's own:
Add jdtls to the ensure_installed for mason. and then set up the lsp config:
That works fine but when i remove it and allow nvim-java to set everything up, I get the above errors.
SlugBoot commentedon Feb 15, 2025
Current workaround I've found from the troubleshooting page is to remove the
config = function()from mason.nvim configuration and using opts insteadfayimora commentedon Feb 15, 2025
@s1n7ax any idea what could be going wrong here?
s1n7ax commentedon Feb 15, 2025
You can find the solution here
https://github.com/nvim-java/nvim-java/wiki/Troubleshooting#no_entry-mason-failed-to-install-jdtls---cannot-find-package-xxxxx
fayimora commentedon Feb 15, 2025
My mason only used opts in the first place but I also tried setting it up with config function as described there but no luck, same issue 🤕
My original conf :
{ "williamboman/mason.nvim", opts = overrides.mason, dependencies = { "WhoIsSethDaniel/mason-tool-installer.nvim", } },Then i tried this:
{ "williamboman/mason.nvim", opts = overrides.mason, dependencies = { "WhoIsSethDaniel/mason-tool-installer.nvim", }, config = function(_, opts) local conf = vim.tbl_deep_extend("keep", opts, overrides.mason) require("mason").setup(conf) end, },s1n7ax commentedon Feb 15, 2025
What is overrides.mason? A function? What does it do?
fayimora commentedon Feb 15, 2025
it's just an object with configs for different plugins to keep the plugin file a bit cleaner:
I printed the config before and after:
s1n7ax commentedon Feb 15, 2025
That's unusual. As a workaround, you can put the registry manually into mason config. Check following file to copy the mason opts.
https://github.com/nvim-java/nvim-java/blob/main/lazy.lua
Do you have the configuration on GitHub?
s1n7ax commentedon Feb 15, 2025
If you are using nvchad, their implementation might be the problem.
I cannot check this now but I'm guessing if a function is passed to opts then previous opts that comes as the second parameter should be merged. In not 100% though. Something like below
opts=function(_, prev_opts)
return merge(prev_opts, custom_opts)
end
s1n7ax commentedon Feb 15, 2025
According to the lazy.nvim documentation, if opts is a function, then the return table will replace parent table.
Please create an issue in nvchad to get it fixed
fayimora commentedon Feb 15, 2025
Interesting. I have Mason defined in my own init lua which i believe overrides what they do. I'll check that.
on another note, writing the registry manually seems to have solved the installation issue. Installation completed but i'm not getting anything(like autocomplete) when i open a java file. Also, everytime i open a new file, mason starts trying to install spring-boot-tools and update java-test
see the changes here alongside the vim config fayimora/dotfiles@ebc2141
s1n7ax commentedon Feb 15, 2025
Well, you should let it install. Nvim-java will not proceed unless there are all the required packages are installe. Nvchad replaced nvim java config and you override nvchad config. I'm closing the ticket since this looks like an issue in the distribution
fayimora commentedon Feb 15, 2025
I did let it finish but getting nothing in java files. Somehow nvim-java is not starting jdtls cause manually installing jdtls lsp give me autocomplete at least.
s1n7ax commentedon Feb 15, 2025
Nvim java does not start the language server. That's for you to do. What this plugin does is setting up packages for you to start jdtls using lspconfig. That's clearly mentioned in the readme
fayimora commentedon Feb 15, 2025
Ah! Should probably put this in the readme then. Readme says:
which i assumed meant it did all the ls stuff too.
I just added it back to my mason
ensure_installedand started it. Everything seems to work fine now! Wow that was quite the ride. Thanks for the assist, much appreciatedfayimora commentedon Feb 15, 2025
Ignore my previous comment about readme. i spent so much time trying to get this work i forgot the readme required you to start jdtls
s1n7ax commentedon Feb 16, 2025
Following fixes the mason registry issue. Please try updating nvim-java and see if everything works with manually adding the nvim-java mason registry
#355
s1n7ax commentedon Feb 16, 2025
Following fixes the mason registry issue. Please try updating nvim-java and see if everything works with manually adding the nvim-java mason registry
#355