NixOS / nixpkgs

Nix Packages collection & NixOS
MIT License
18.1k stars 14.15k forks source link

Update request: rPackages.stray 0.1.1 → 0.1.3 #226619

Closed SebTM closed 1 year ago

SebTM commented 1 year ago

Notify maintainers Unsure maybe @jbedo @Et7f3

Wanted to try stray integration in hybrid-bar but needs 0.1.3 which is not published on https://cran.r-project.org/ but on https://crates.io/crates/stray but as the rPackages build-system is quite complex I wasn't able to archive it on my own in reasonable time. Tried to override sources in r-modules/default.nix under otherOverrides:

    stray = old.stray.overrideAttrs (attrs: {
      src = pkgs.fetchzip {
        url = "https://github.com/oknozor/stray/archive/refs/tags/0.1.3.zip";
        sha256 = "sha256-LWlKIxQnVu70GY7e5U2beTjX/XmJd3Dlm0NONH46/F4=";
      };
    });

but this fails with:

error: builder for '/nix/store/d8xy5kkdpr87w7a6kxslay78wzjgm3v1-r-stray-0.1.1.drv' failed with exit code 1;
       last 10 log lines:
       > unpacking sources
       > unpacking source archive /nix/store/hv1qxx8sdzb5sdl7fjx646ssf0arnci6-source
       > source root is source
       > patching sources
       > configuring
       > building
       > running tests
       > installing
       > Warning: invalid package '.'
       > Error: ERROR: no packages specified
       For full logs, run 'nix log /nix/store/d8xy5kkdpr87w7a6kxslay78wzjgm3v1-r-stray-0.1.1.drv'.

How can I get cran to publish the update or do a proper override?


Note for maintainers: Please tag this issue in your PR.

jbedo commented 1 year ago

You're getting confused because of a naming clash, the stray in rPackages is the R package published on CRAN for doing anomaly detection, it has nothing to do with the stray crate which is a rust module. Your error message is R saying it can't find a valid R package in the tarball you pointed it to.

SebTM commented 1 year ago

Thanks for the explanation, so the dependency will already be installed with cargo via and cargoHash?

Et7f3 commented 1 year ago

Thanks for the explanation, so the dependency will already be installed with cargo via and cargoHash?

From manual it seem to import all deps mentionned in cargo.lock