Skip to content
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

go: 1.12.7 -> 1.12.8, 1.11.12 -> 1.11.13 #66595

Closed
wants to merge 1 commit into from
Closed

go: 1.12.7 -> 1.12.8, 1.11.12 -> 1.11.13 #66595

wants to merge 1 commit into from

Conversation

fmpwizard
Copy link
Contributor

Motivation for this change

Upstream update (this is a security update that affects http2)

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nix-review --run "nix-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.
Notify maintainers

cc @rvolosatovs


First time contributing here so a few notes, this is who I got the sha256, but note how the one I got for the 1.12.7 doesn't match what is on master right now:

$ nix-prefetch-url --unpack https://dl.google.com/go/go1.12.7.src.tar.gz
unpacking...
[21.0 MiB DL]
path is '/nix/store/mz292x2airgwp2mh0v9nmj0wavw7aj56-go1.12.7.src.tar.gz'
16zf3jxrji01rxn318hqmm6yhp5qjgg2k11ypadm1x2w7rdpr39j
$ nix-prefetch-url --unpack https://dl.google.com/go/go1.12.8.src.tar.gz
unpacking...
[21.0 MiB DL]
path is '/nix/store/ypyn3m33zbr60h9vqk9j5i6lzxprgn1k-go1.12.8.src.tar.gz'
1wamgb1kk379ys6v9vr60lnvrbnr2vvdshx2ahhpc86yzix2yl79
$ nix-prefetch-url --unpack https://dl.google.com/go/go1.11.13.src.tar.gz
unpacking...
[20.1 MiB DL]
path is '/nix/store/rf6wll3sajsl0xhzs2lm649vfmq2z54q-go1.11.13.src.tar.gz'
0vr95zb2rky42wfh1jd4fvbm9wcq1mnii0742pfx7j8h7kk83462

Then, I tried to follow docs about submitting changes, but this part:

nix-env -i pkg-name -f <path to your local nixpkgs folder>

gives me:

$ nix-env -i go -f pkgs/
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/applications/editors/vscode/generic.nix'
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/applications/editors/yi/wrapper.nix'
error: too many Nix expressions in directory '/home/diego/work/ascendant/nixpkgs/pkgs/applications/misc'

I also tried passing a closer path to the go compiler nix file:

$ nix-env -i go -f pkgs/development/compilers
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/development/compilers/gcc/5'
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/development/compilers/llvm/4'
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/development/compilers/llvm/5'
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/development/compilers/llvm/6'
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/development/compilers/llvm/7'
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/development/compilers/llvm/8'
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/development/compilers/mono/4.nix'
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/development/compilers/mono/5.nix'
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/development/compilers/mozart/binary.nix'
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/development/compilers/ocaml/generic.nix'
warning: name collision in input Nix expressions, skipping '/home/diego/work/ascendant/nixpkgs/pkgs/development/compilers/oraclejdk/jdk-linux-base.nix'
error: cannot auto-call a function that has an argument without a default value ('stdenv')

If you can spell it out for me, I can run any testing I need to.

For reference, this update comes with some pretty big security fixes https://groups.google.com/d/topic/golang-nuts/fCQWxqxP8aA/discussion

@Mic92
Copy link
Member

Mic92 commented Aug 14, 2019

I get a different checksum for go 1.12:

hash mismatch in fixed-output derivation '/nix/store/mr57wpg9z4685vlmdz15nkb9r7hxvv37-go1.12.8.src.tar.gz':
  wanted: sha256:1wamgb1kk379ys6v9vr60lnvrbnr2vvdshx2ahhpc86yzix2yl79
  got:    sha256:164q7i2h6bcc7icyvnjq6djla61fzadvxzxxlbwgqqzz64p2xb8i

@fmpwizard
Copy link
Contributor Author

@Mic92 and you got that different hash running:

nix-prefetch-url --unpack https://dl.google.com/go/go1.12.8.src.tar.gz

?

In case it's a version thing:

nix-prefetch-url --version
nix-prefetch-url (Nix) 2.2.2

@rvolosatovs
Copy link
Member

Fixed builds and updated to 1.12.9 in #66894 (added @fmpwizard as co-author)

@fmpwizard
Copy link
Contributor Author

thanks! I'll close this one now.

@fmpwizard fmpwizard closed this Aug 19, 2019
@fmpwizard fmpwizard deleted the update_go branch August 19, 2019 12:39
@fmpwizard
Copy link
Contributor Author

In case anyone ends here with the issue of not matching sha256 when trying to submit a PR, instead of:

nix-prefetch-url --unpack https://dl.google.com/go/go1.12.7.src.tar.gz

you need

nix-prefetch-url https://dl.google.com/go/go1.12.7.src.tar.gz

Don't pass the --unpack parameter

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

Successfully merging this pull request may close these issues.

None yet

4 participants