feat(args): query --releases for channels (plus minor fixes) #78
+537
−165
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
some background
Release tests are special hydra jobs that determine whether channel updates are okay to be released or instead should be blocked. This is nicely described in the wiki page https://wiki.nixos.org/wiki/Channel_branches.
The release tests for all channels are defined here and listed on https://status.nixos.org in the "Hydra job for tests" column, where it also shows the history for each test.
motivations & solutions
The ability to query the status of release tests would be valuable for users if we want to pin our local nixpkgs to a "nice" historical commit. These test jobs are similar to usual package jobs in hydra, so we can simply query their status with hydra-check. In previous versions we can already do this manually with e.g.
where we have manually specified the job name "unstable" as the release test for the
nixpkgs-unstablechannel (and--arch=""since this is a special job in hydra that does not contain the architecture in its name). The job name may be different for each channel and one needs to look it up on https://status.nixos.org before actually querying it. For example, the release test job name fornixos-unstableis called "tested".This PR adds a new
--releasesflag which automates the above process. Now we can simply do:which is equivalent to the previous query, combined with information of recent channel evals, basically providing the same information as in https://status.nixos.org.
Along the way, we also improve channel guessing by preferringnixpkgs-XX.XX-darwinon darwin (instead ofnixos/release-XX.XXwhich was the previous default). This is arranged in a separate commit.Update: this PR has grown too large so I will be cherry-picking parts of it and merge them step by step. These include the quality of life improvements in #84. Expect the number of commits here to decrease after these minor updates are merged into master.