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
0.kind: enhancementAdd something new or improve an existing system.2.status: stalehttps://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md6.topic: rustGeneral-purpose programming language emphasizing performance, type safety, and concurrency.
Having to update rustRegistry manually is super annoying when you're developing in Rust.
I propose adding a script to nixpkgs that can generate the latest version, and then put a .travis.yml in a repo that calls the script and submits a PR, invoked daily by Nightli.es. Alternatively, it could be a cronjob running on nixos.org infrastructure. This would also be reusable for other packages.
Given that snapshot update can't break anything in theory (we require Cargo.lock files to ensure dependencies' determinism in our Rust packages, and upstream keeps all old package versions there) I'm all for automated updating. I don't think spamming nixpkgs with automated PRs is a good thing, however. Maybe, given that I can't think of a situation when a snapshot update is harmful, we want to just push updates directly to master. Before doing that, however, we must carefully ensure that upstream is committed to keep all old package versions there and doesn't have an npm-style "unpublish" procedure (i.e. what's got into repository stays there and can only be "hidden" from search maybe).
You're right about directly pushing to master; after a while, nobody's going to check generated commits anyway and will just hit merge. In the unlikely case something breaks, we can always revert it.
I really like the way the rust infrastructure works in Nix relative to the other languages where you have to use Nix file generators, depsSha256 and then making Cargo deterministic is clever.
Specifically for how the script updates the crates index, perhaps this new Nix feature might be of some use: NixOS/nix@06f29fa
I think that should let it prefetch directly based on the fetchFromGitHub call in rust-packages.nix.
But otherwise we can just figure out the correct URL and use nix-prefetch-url, then update the URL and SHA256 in rust-packages.nix
Here's some other things it could update (not necessarily in first implementation, but eventually):
This would allow creating a local registry with only the package specified in a Cargo.toml file. This should be constant over time (and is verfiied by hashes) and would eliminate the need to have the registry package at all.
I might try to get it working but I'm not faimilar with the rust packaging and the tool itself has a number of dependencies which I would probably need to build manually to avoid a circular dependency.
This has been automatically marked as stale because it has had no activity for 180 days.
If this is still important to you, we ask that you leave a comment below. Your comment can be as simple as "still important to me". This lets people see that at least one person still cares about this. Someone will have to do this at most twice a year if there is no other activity.
Here are suggestions that might help resolve this more quickly:
Search for maintainers and people that previously touched the related code and @ mention them in a comment.
0.kind: enhancementAdd something new or improve an existing system.2.status: stalehttps://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md6.topic: rustGeneral-purpose programming language emphasizing performance, type safety, and concurrency.
Activity
abbradar commentedon Apr 5, 2016
Given that snapshot update can't break anything in theory (we require
Cargo.lockfiles to ensure dependencies' determinism in our Rust packages, and upstream keeps all old package versions there) I'm all for automated updating. I don't think spamming nixpkgs with automated PRs is a good thing, however. Maybe, given that I can't think of a situation when a snapshot update is harmful, we want to just push updates directly to master. Before doing that, however, we must carefully ensure that upstream is committed to keep all old package versions there and doesn't have an npm-style "unpublish" procedure (i.e. what's got into repository stays there and can only be "hidden" from search maybe).jgillich commentedon Apr 5, 2016
Crates.io never had an unpublish feature, they only remove things for legal reasons: https://www.reddit.com/r/rust/comments/4bm3rk/how_would_cratesio_react_in_a_case_similar_to_the/d1bqxc0
You're right about directly pushing to master; after a while, nobody's going to check generated commits anyway and will just hit merge. In the unlikely case something breaks, we can always revert it.
trishume commentedon Apr 5, 2016
This sounds good to me.
I really like the way the rust infrastructure works in Nix relative to the other languages where you have to use Nix file generators, depsSha256 and then making Cargo deterministic is clever.
Specifically for how the script updates the crates index, perhaps this new Nix feature might be of some use: NixOS/nix@06f29fa
I think that should let it prefetch directly based on the
fetchFromGitHubcall inrust-packages.nix.But otherwise we can just figure out the correct URL and use nix-prefetch-url, then update the URL and SHA256 in
rust-packages.nixHere's some other things it could update (not necessarily in first implementation, but eventually):
kevincox commentedon Aug 4, 2017
I think that this can be fixed with https://github.com/alexcrichton/cargo-local-registry
This would allow creating a local registry with only the package specified in a Cargo.toml file. This should be constant over time (and is verfiied by hashes) and would eliminate the need to have the registry package at all.
I might try to get it working but I'm not faimilar with the rust packaging and the tool itself has a number of dependencies which I would probably need to build manually to avoid a circular dependency.
stale commentedon Jun 5, 2020
Thank you for your contributions.
This has been automatically marked as stale because it has had no activity for 180 days.
If this is still important to you, we ask that you leave a comment below. Your comment can be as simple as "still important to me". This lets people see that at least one person still cares about this. Someone will have to do this at most twice a year if there is no other activity.
Here are suggestions that might help resolve this more quickly:
Artturin commentedon Mar 1, 2023
we don't have a rustRegistry anymore