From 574680f38e01f150d70aee7164926389d349362a Mon Sep 17 00:00:00 2001 From: chavic Date: Fri, 10 Jul 2026 17:42:50 +0200 Subject: [PATCH] Use the binary dotnet SDK on all platforms The Darwin-only conditional from #1723 assumed hydra serves the source-built VMR SDK from cache on Linux. It does not on the pinned nixpkgs rev: CI logs show ubuntu-latest fetching the 1xx binary SDK only to bootstrap a from-source dotnet-vmr-10.0.301 build that takes ~25 minutes, while the tests themselves finish in under a minute. Nothing is cached between runs, so every pull request pays the rebuild. Drop the conditional and use the Microsoft-binary SDK everywhere. This also insulates the dev shells from future nixpkgs bumps landing on VMR revisions hydra has not built yet. --- flake.nix | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/flake.nix b/flake.nix index 6afbfdf41..4e8cc538d 100644 --- a/flake.nix +++ b/flake.nix @@ -259,16 +259,12 @@ "payjoin-mailroom-image" = mkContainerImage "payjoin-mailroom" packages.payjoin-mailroom tag; }; - # On Darwin the default sdk_10_0 resolves to the source-built VMR, which has - # no binaries in the public nix cache: every uncached realization compiles - # the entire .NET SDK from source (hours on CI runners and contributor - # machines). Use the Microsoft-binary SDK there; Linux keeps the - # source-built SDK, which hydra serves from cache. - dotnetSdk = - if pkgs.stdenv.isDarwin then - pkgs.dotnetCorePackages.sdk_10_0_1xx-bin - else - pkgs.dotnetCorePackages.sdk_10_0; + # The default sdk_10_0 resolves to the source-built VMR, whose binaries + # are not reliably in the public nix cache on any platform (the pinned + # nixpkgs rev's VMR is unbuilt on hydra): every uncached realization + # compiles the entire .NET SDK from source (~25 min on Linux CI runners, + # hours on macOS). Use the Microsoft-binary SDK everywhere. + dotnetSdk = pkgs.dotnetCorePackages.sdk_10_0_1xx-bin; devShells = builtins.mapAttrs ( _name: craneLib: