-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
[flake] Option to print hash mismatches in base32 instead of base64 #3786
Comments
This is where the hash mismatch message is computed: https://github.com/NixOS/nix/blob/flakes/src/libstore/build.cc#L3749 |
I have it on good authority that is fine to use SRI hashes on master. The only issue at hand is backports to 20.03 I guess. |
I thought this was a duplicate of another issue but apparenly it was PR: #3433 |
I'd prefer if we close this and start migrating to base64 naturally. As mentioned these are fine on master now, and they have the advantage of being shorter and also are a standard encoding that exists in the wider world outside the nix ecosystem. |
One "downside" that @infinisil brought up on IRC is that certain characters are delimiters for double-clicking, making copying correct hashes slightly more cumbersome. I would still consider this feature at least somewhat desirable ("nice to have"), but not because we don't support base64 hashes in Nixpkgs. |
Ok. I was not aware that we can already depend on it. |
Is your feature request related to a problem? Please describe.
Right now when a checksum fails the error message in nixFlakes looks like this:
Describe the solution you'd like
However we cannot use base64 in nixpkgs yet. Therefor it would be good to have an option to use base64 or base32 hashes instead.
Describe alternatives you've considered
There is
nix to-base32
for conversion however this is time consuming. People also might accidentally make pull requests using the new hash format also we cannot support this yet.The text was updated successfully, but these errors were encountered: