Failed to package zola 0.19.0: dependencies require newer rustc version

Hello,

Zola 0.19.0 has been released a few days ago and I am trying to update the package definition in nixpkgs. I forked the repo from master and tried to update the version number and hashs to match the new version however, it seems that some dependencies of zola@0.19.0 needs a newer version of rustc than that available in nixpkgs on master. I don’t know if this is problem on my side or a limitation of the current state of nixpkgs.

See the full build log below:

➜ nix log /nix/store/59i453y1hqs4ak79ss6l4pj6jg16whsa-zola-0.19.0.drv
warning: The interpretation of store paths arguments ending in `.drv` recently changed. If this command is now failing try again with '/nix/store/59i453y1hqs4ak79ss6l4pj6jg16whsa-zola-0.19.0.drv^*'
@nix { "action": "setPhase", "phase": "unpackPhase" }
Running phase: unpackPhase
unpacking source archive /nix/store/grrq90wdfg7qfy5w3rdaxxa9x14wf3yx-source
source root is source
Executing cargoSetupPostUnpackHook
unpacking source archive /nix/store/s5q7ybwpc4n5ic7qaa2l93rh01f30n17-zola-0.19.0-vendor.tar.gz
Finished cargoSetupPostUnpackHook
@nix { "action": "setPhase", "phase": "patchPhase" }
Running phase: patchPhase
Executing cargoSetupPostPatchHook
Validating consistency between /build/source/Cargo.lock and /build/zola-0.19.0-vendor.tar.gz/Cargo.lock
Finished cargoSetupPostPatchHook
@nix { "action": "setPhase", "phase": "updateAutotoolsGnuConfigScriptsPhase" }
Running phase: updateAutotoolsGnuConfigScriptsPhase
@nix { "action": "setPhase", "phase": "configurePhase" }
Running phase: configurePhase
@nix { "action": "setPhase", "phase": "buildPhase" }
Running phase: buildPhase
Executing cargoBuildHook
++ env CC_X86_64_UNKNOWN_LINUX_GNU=/nix/store/mpm3i0sbqc9svfch6a17179fs64dz2kv-gcc-wrapper-13.3.0/bin/cc CXX_X86_64_UNKNOWN_LINUX_GNU=/nix/store/mpm3i0sbqc9svfch6a17179fs64dz2kv-gcc-wrapper-13.3.0/bin/c++ CARGO_T>
warning: `/build/.cargo/config` is deprecated in favor of `config.toml`
note: if you need to support cargo 1.38 or earlier, you can symlink `config` to `config.toml`
warning: `/build/.cargo/config` is deprecated in favor of `config.toml`
note: if you need to support cargo 1.38 or earlier, you can symlink `config` to `config.toml`
error: rustc 1.78.0 is not supported by the following packages:
  bitstream-io@2.4.1 requires rustc 1.79
  ravif@0.11.7 requires rustc 1.79
Either upgrade rustc or select compatible dependency versions with
`cargo update <name>@<current-ver> --precise <compatible-ver>`
where `<compatible-ver>` is the latest version supporting rustc 1.78.0

and the full package definition (pkgs/by-name/zo/zola/package.nix)

{
  lib,
  stdenv,
  fetchFromGitHub,
  rustPlatform,
  pkg-config,
  oniguruma,
  darwin,
  installShellFiles,
  zola,
  testers,
}:
rustPlatform.buildRustPackage rec {
  pname = "zola";
  version = "0.19.0";

  src = fetchFromGitHub {
    owner = "getzola";
    repo = "zola";
    rev = "v${version}";
    hash = "sha256-OSSLPklPmpMd6nPRiuUKlA3SZ2vZm0JpTp2VdP5vkpA=";
  };

  cargoHash = "sha256-yTOSF2buKqxJC1WBFQ7slNNO0UiFsnJXB9nYSKHzILA=";

  nativeBuildInputs = [
    pkg-config
    installShellFiles
  ];

  buildInputs =
    [
      oniguruma
    ]
    ++ lib.optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks; [
      CoreServices
      SystemConfiguration
    ]);

  postInstall = ''
    installShellCompletion --cmd zola \
      --bash <($out/bin/zola completion bash) \
      --fish <($out/bin/zola completion fish) \
      --zsh <($out/bin/zola completion zsh)
  '';

  passthru.tests.version = testers.testVersion {package = zola;};

  meta = with lib; {
    description = "Fast static site generator with everything built-in";
    mainProgram = "zola";
    homepage = "https://www.getzola.org/";
    changelog = "https://github.com/getzola/zola/raw/v${version}/CHANGELOG.md";
    license = licenses.mit;
    maintainers = with maintainers; [dandellion dywedir _0x4A6F];
  };
}

I am very much a noob at nix packaging… If you have any ideas, let me know.

This would be waiting on cargo,clippy,rustc,rustfmt: 1.78.0 -> 1.79.0 by alyssais · Pull Request #320250 · NixOS/nixpkgs · GitHub to be merged, as that bumps the rust compiler version to 1.79.0. It is a nixpkgs limitation that we only have one rustc version in-tree at any one time.