Skip to content

radicle: init #5409

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

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft

Conversation

lorenzleutgeb
Copy link

Description

Radicle is a distributed code forge based on Git. I recently overhauled the package in Nixpkgs and have been using programs.radicle (for basic configuration of Radicle) and services.radicle (for managing radicle-node and radicle-http as systemd user services) for a few weeks without problems (links to my personal repo).

I could need some help with the tests. home-files/.radicle seems to be missing and I don't understand why:

$ ls -la /nix/store/afg8b60b5a79ziw03yfiwdcmmnis58l3-nmt-report-radicle-basic-configuration/tested/home-files
dr-xr-xr-x - root 1970-01-01 02:00 .cache
dr-xr-xr-x - root 1970-01-01 02:00 .config
dr-xr-xr-x - root 1970-01-01 02:00 asserts

Checklist

  • Change is backwards compatible. (Trivially, since there is no earlier version.)
  • Code formatted with ./format.
  • Code tested through nix-shell --pure tests -A run.all or nix develop --ignore-environment .#all using Flakes.
  • Test cases updated/added. See example.
  • Commit messages are formatted.
  • Added myself as module maintainer.

@ju1m
Copy link

ju1m commented May 21, 2024

Thanks a lot @lorenzleutgeb for the nixpkgs PR and this draft!
Here's the changes I had to do to make progress https://github.com/ju1m/home-manager/commits/radicle/
Alas, with nixos-23.11's rustc, building radicle-node (after cherry-picking the nixpkgs PR) fails:

radicle-node> Found a `cargo::key=value` build directive which is reserved for future use.                                                                                                                                                                     
radicle-node> Either change the directive to `cargo:key=value` syntax (note the single `:`) or upgrade your version of Rust.                                                                                                                                   
radicle-node> See https://doc.rust-lang.org/cargo/reference/build-scripts.html#outputs-of-the-build-script for more information about build script outputs.

so I'll have to update to the upcoming nixos-24.05 before trying this further more.

@lorenzleutgeb
Copy link
Author

Hey! Thanks for your help.

If you like, you can also try the Flake at https://github.com/lorenzleutgeb/heartwood in the meantime.

I also have things coming at https://github.com/lorenzleutgeb/radicle-nix, including more changes to the modules in this PR...

What I don't understand is why you reverted to http://github.com/lorenzleutgeb/nur ? The formatting in these files does not conform to home-manager's requirements.

@ju1m
Copy link

ju1m commented May 21, 2024

If you like, you can also try the Flake at https://github.com/lorenzleutgeb/heartwood in the meantime.

Thanks @lorenzleutgeb

I also have things coming at https://github.com/lorenzleutgeb/radicle-nix, including more changes to the modules in this PR...

Nice to also have a NixOS service, do you plan to open a PR to upstream it?
Just in passing, something that should be checked is whether LoadCredential= can load a path from LoadCredentialEncrypted=, otherwise we may have to add some logic to support LoadCredentialEncrypted=.

What I don't understand is why you reverted to http://github.com/lorenzleutgeb/nur ? The formatting in these files does not conform to home-manager's requirements.

Well it's only after seeing that there were differences between this PR and the NUR version, and that the NUR contained two fixes (services.radicle.httpd.environnement.default's cfg.node.enable => {} and {RestartDelayMaxSec => RestartMaxDelaySec}) while looking more advanced on socket activation, that I rebased my changes on the NUR version. The formatting can always be fixed later on.

Nice to see you're actively working on this, happy to review your changes on this PR whenever you're ready to push them.

Copy link

stale bot commented Aug 23, 2024

Thank you for your contribution! I marked this pull request as stale due to inactivity. Please read the relevant sections below before commenting.

If you are the original author of the PR

  • GitHub sometimes doesn't notify people who commented / reviewed a PR previously when you (force) push commits. If you have addressed the reviews you can officially ask for a review from those who commented to you or anyone else.
  • If it is unfinished but you plan to finish it, please mark it as a draft.
  • If you don't expect to work on it any time soon, please consider closing it with a short comment encouraging someone else to pick up your work.
  • To get things rolling again, rebase the PR against the target branch and address valid comments.

If you are not the original author of the PR

  • If you want to pick up the work on this PR, please create a new PR and indicate that it supercedes and closes this PR.

@matthiasbeyer
Copy link
Contributor

@lorenzleutgeb please have a look at https://github.com/matthiasbeyer/home-manager/tree/radicle (git fetch https://github.com/matthiasbeyer/home-manager radicle && git checkout FETCH_HEAD) which is a rebase + fixup commits of this PR.

All patches that I think are uncontroversial are committed as --fixup commits. The others have proper commit messages.

I did not touch your initial commit, modulo the rebase changes that were necessary.

I committed my changes in a way where I think it is best if you review them commit-by-commit.

@lorenzleutgeb
Copy link
Author

@matthiasbeyer thanks a lot! I squashed your changes in. Next I will see what CI has to say, and then integrate changes I made to my personal configuration in the meantime.

@lorenzleutgeb lorenzleutgeb force-pushed the radicle branch 4 times, most recently from 432be27 to 9c73e30 Compare August 18, 2025 16:54
@lorenzleutgeb lorenzleutgeb force-pushed the radicle branch 2 times, most recently from 4f33b97 to 46c0c39 Compare August 18, 2025 20:38
Co-authored-by: Matthias Beyer <[email protected]>
@khaneliman
Copy link
Collaborator

Looks like it needs nix fmt and test error:

nmt-test-radicle-basic-configuration>
error: builder for '/nix/store/n8xvqw23ysn3r8n4ilaq9y8vrrsq3sl7-nmt-test-radicle-basic-configuration.drv' failed with exit code 1;
last 3 log lines:
> diff: /nix/store/jcvkswcb12lvgsrrdnb97rqjwnfjhd18-home-manager-generation/home-files/.radicle/config.json: No such file or directory
> Expected home-files/.radicle/config.json to be same as /nix/store/39gc85n30s5qsij1dn620qabzpwl29jb-basic-configuration.json but were different:

building '/nix/store/kk86pr5r64snk8gf7lgsb1n713rrc9i9-home-manager-files.drv'...
options.json> error: option programs.radicle.environment has no description
options.json> error: option programs.radicle.httpd.args has no description
options.json> error: option programs.radicle.node.args has no description
options.json> error: option programs.radicle.settings has no description
options.json> error: option programs.radicle.settings.cli has no description
options.json> error: option programs.radicle.settings.cli.hints has no description
options.json> error: option programs.radicle.settings.node has no description
options.json> error: option programs.radicle.settings.node.alias has no description
options.json> error: option programs.radicle.settings.node.network has no description
options.json> error: option programs.radicle.settings.node.peers has no description
options.json> error: option programs.radicle.settings.node.peers.target has no description
options.json> error: option programs.radicle.settings.node.peers.type has no description
options.json> error: option programs.radicle.settings.node.policy has no description
options.json> error: option programs.radicle.settings.node.relay has no description
options.json> error: option programs.radicle.settings.node.scope has no description
options.json> error: option programs.radicle.settings.node.workers has no description
options.json> error: option programs.radicle.settings.preferredSeeds has no description
options.json> error: option programs.radicle.settings.publicExplorer has no description
options.json> error: option programs.radicle.settings.web has no description
options.json> error: option programs.radicle.settings.web.pinned has no description
options.json> error: option programs.radicle.settings.web.pinned.repositories has no description
options.json> error: option programs.radicle.uri.rad.browser.preferredNode has no description
options.json> error: option programs.radicle.uri.rad.vscode.extension has no description
options.json> error: option services.radicle.httpd.args has no description
options.json> error: option services.radicle.httpd.environment has no description
options.json> error: option services.radicle.node.args has no description
options.json> error: option services.radicle.node.environment has no description

@matthiasbeyer
Copy link
Contributor

It also seems that nixpkgs needs to be refreshed:

error: radicle-cli cannot be found in pkgs

I don't know how this mechanic works in home-manager, so I cannot comment on that. But without radicle-cli, this PR is not possible 😆

@lorenzleutgeb
Copy link
Author

lorenzleutgeb commented Aug 19, 2025

@khaneliman, @matthiasbeyer thanks for your attention, but please don't waste your time reviewing this just yet. I know how to make my way through CI failures, and I will change the status of the PR from "Draft" to "Ready for review" when ... well, when it is ready for review.

In the meantime, feel free to push actual fixes like @matthiasbeyer did in #5409 (comment), but posting errors that CI can catch is just noise to me, TBH.

Thanks for your understanding.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants