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

Add gzip decompression support #3256

Closed
ocharles opened this issue Dec 5, 2019 · 4 comments · Fixed by #3266
Closed

Add gzip decompression support #3256

ocharles opened this issue Dec 5, 2019 · 4 comments · Fixed by #3266

Comments

@ocharles
Copy link

ocharles commented Dec 5, 2019

The following is enough to reproduce:

$ nix-build -E 'builtins.fetchTarball {name = "nixpkgs"; url = "https://github.com/NixOS/nixpkgs/archive/5f7eae4bbb15ce7fa4da1984fd6ba5be7af50952.tar.gz"; sha256 = "0pqhvq66s9z7pzscmz3h9vffybalvdnijw1z5c5kkx0c9d6dnjvr";}'
unpacking 'https://github.com/NixOS/nixpkgs/archive/5f7eae4bbb15ce7fa4da1984fd6ba5be7af50952.tar.gz'...
error: numeric field did not have utf-8 text: n����}#� when getting cksum for �

I am running NixOS with:

{
  nix = {
      systemFeatures =
        [ "benchmark" "big-parallel" "kvm" "nixos-test" "recursive-nix" "nix-command" ];

      extraOptions =
        ''
        experimental-features = recursive-nix nix-command
        '';

      package =
        let
          src =
            pkgs.fetchFromGitHub
              { owner =
                  "NixOS";

                repo =
                  "nix";

                rev =
                  "ac2bc721d84f3c6c214212e41808a45fa792c6e8";

                sha256 =
                  "1y5r9g7x244gvh511xkxqhcy1zydyx7rp38lzd5dnra5h9ja5gk0";
              };

        in
        ( import "${src}/release.nix" { nix = src; officialRelease = true; } ).build.x86_64-linux;
    };
}
@ocharles
Copy link
Author

ocharles commented Dec 5, 2019

Removing the package override the example works, so it seems to be a regression.

@edolstra
Copy link
Member

edolstra commented Dec 5, 2019

Probably caused by #2748.

@edolstra
Copy link
Member

edolstra commented Dec 5, 2019

Oh yeah:

            // FIXME: add .gz support

:-)

@edolstra edolstra changed the title "numeric field did not have utf-8 text" when using fetchTarball Add gzip decompression support Dec 5, 2019
tomberek pushed a commit to tomberek/nix that referenced this issue Dec 13, 2019
tomberek pushed a commit to tomberek/nix that referenced this issue Dec 13, 2019
dtzWill pushed a commit to dtzWill/nix that referenced this issue Dec 15, 2019
Closes NixOS#3256

(cherry picked from commit c6295a3)
@nixos-discourse
Copy link

This issue has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/unable-to-use-gzip-in-derivation/12173/1

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

Successfully merging a pull request may close this issue.

3 participants