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
"Break" the build on non-unstable Nixpkgs version #168
Comments
This can be done by using nix flakes to pin to a particular unstable commit. Allowing both the developer and end users more flexibility. With this we can pin a configuration to both a nixpkgs and a mobile-nixos version.
flake.lock
|
Until flakes is a feature part of Nix stable, this will not be made using flakes... Additionally, Mobile NixOS has to be able to be used by the end-user's channel revision of their choice. Pinning the version of Nixpkgs is not a goal. This is because I don't want this project to decide which Nixpkgs version the user uses, they could be using their own fork, or requiring the latest release for security updates! When Mobile NixOS will be a bit more stable, it will get stable branches as NixOS does, so "breaking" the build for Nixpkgs releases too low will not be an issue. |
Using nix flakes for mobile-nixos and given that nixpkgs already uses it would be less about mobile-nixos forcing a version on a user and more about a user being able to pin both on a flake.nix, share on a gist, etc. For the time being, your suggestion to look at latest builds in Hydra and then find the last successful build I think satisfies most of the early adopter needs. We just need to mention it more prominently if possible. https://hydra.nixos.org/build/123368707
True |
The main idea would be to check the Nixpkgs version (e.g. 20.09) and if lower error out of the build.
Though, this should only error out if it's known bad, so the next update, (21.03) should add a warning that it's only known to successfully build on Unstable, and that success may be variable. Once it is known that it won't build against, increase the minimum required version.
So, in this scheme, we have two variables:
minimumRequiredNixpkgsVersion
break when the current version is lowertestedNixpkgsVersion
warn when the current version is lowerThis would be a build-time UX improvement, reducing the risks that a user (rightfully) won't know why the builds fail.
This would help for issues like #166.
The text was updated successfully, but these errors were encountered: