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
buildMaven: Check for authenticated attribute #44091
Conversation
The `authenticated` attribute is not always present in the `project-info.json` produced by maven2nix[0] We therefore check for its presence, and default it to false. [0]: NixOS/mvn2nix-maven-plugin#5 (comment)
There is actually a deeper problem here, which is that if |
Not sure I follow ... |
TL;DR: this pull request fixes evaluation, but not the build. (*) For our purposes, the main reason maven reports remote dependencies as local dependencies is if they are cached locally. I consider this a serious flaw; caching should be transparent! |
Ah, okay, gotcha -- that makes sense, thanks for figuring it out. (And I agree it's a serious flaw in Maven!) So in some sense it's yet another reason to use the FWIW, I'm still not entirely convinced that a maven plugin is the right way to figure out the complete set of maven dependencies for a project, at least not without some upstream work on maven itself. See discussion at #19741. Maybe it's worth a post to the maven dev team's mailing list to try to figure some of this out with their help? Even something general like "hey, what would it take to get maven to produce a lock file like |
Does it work for you though? I've just tried it on the K repo and it didn't. |
I haven't tried it, no. :-/ |
It does not, because of NixOS/mvn2nix-maven-plugin#15. I fixed that, and it still does not work because maven will always resolve the I think the only way forward is to fetch the dependencies through maven itself. I am working on that now. I am still having problems because the K |
@ttuegel are you using There are 2 existing attempts using |
Sorry for the confusion -- my script in #19741 is meant for after running a regular build, not |
Yes, I found that. However, a newer version of |
@ttuegel Is your work-in-progress available somewhere? |
Motivation for this change
The
authenticated
attribute is not always present in theproject-info.json
produced by maven2nix0We therefore check for its presence, and default it to false.
Things done
sandbox
innix.conf
on non-NixOS)nix-shell -p nox --run "nox-review wip"
./result/bin/
)nix path-info -S
before and after)