From 3bd158e72e6a22a4505479360e05a84b0c83a503 Mon Sep 17 00:00:00 2001 From: Daniel Woffinden Date: Sun, 12 Jul 2026 22:35:36 +0100 Subject: [PATCH] cgt-calc: fix build by backporting uv-build relaxation On latest unstable: ``` ERROR Missing dependencies: uv_build<0.11.0,>=0.8.23 error: Cannot build '/nix/store/w9vn8bl71zib3lgf4dfrdkrfasz9alnx-cgt-calc-2.0.0.drv'. Reason: builder failed with exit code 1. Output paths: /nix/store/kg4zwzbh10vn51h0r6g6jmlhh0wb6k93-cgt-calc-2.0.0-dist /nix/store/wnr2qzvnw7l0czbaa0qqm2wdjyfrbnfb-cgt-calc-2.0.0 Last 25 log lines: > Using pypaBuildPhase > Sourcing python-runtime-deps-check-hook > Using pythonRuntimeDepsCheckHook > Sourcing pypa-install-hook > Using pypaInstallPhase > Sourcing python-imports-check-hook.sh > Using pythonImportsCheckPhase > Sourcing python-namespaces-hook > Sourcing python-catch-conflicts-hook.sh > Running phase: unpackPhase > unpacking source archive /nix/store/xf1v660b4w4kv0sk1qhwx5lx9gapacgz-source > source root is source > setting SOURCE_DATE_EPOCH to timestamp 315619200 of file "source/uv.lock" > Running phase: patchPhase > Running phase: updateAutotoolsGnuConfigScriptsPhase > Running phase: configurePhase > no configure script, doing nothing > Running phase: buildPhase > Executing pypaBuildPhase > Creating a wheel... > pypa build flags: --no-isolation --outdir dist/ --wheel > * Getting build dependencies for wheel... > > ERROR Missing dependencies: > uv_build<0.11.0,>=0.8.23 For full logs, run: nix log /nix/store/w9vn8bl71zib3lgf4dfrdkrfasz9alnx-cgt-calc-2.0.0.drv ``` Fix is upstream but not yet released: https://github.com/KapJI/capital-gains-calculator/pull/781 --- pkgs/by-name/cg/cgt-calc/package.nix | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/pkgs/by-name/cg/cgt-calc/package.nix b/pkgs/by-name/cg/cgt-calc/package.nix index 700ead59662e..482be86743b2 100644 --- a/pkgs/by-name/cg/cgt-calc/package.nix +++ b/pkgs/by-name/cg/cgt-calc/package.nix @@ -1,6 +1,7 @@ { lib, fetchFromGitHub, + fetchpatch, python3Packages, withTeXLive ? true, texliveSmall, @@ -17,6 +18,15 @@ python3Packages.buildPythonApplication (finalAttrs: { hash = "sha256-KPzADW+n82X08IMfSIl5JyYPm8fxbbowud8sBdUxRgA="; }; + patches = [ + (fetchpatch { + # https://github.com/KapJI/capital-gains-calculator/pull/781 + name = "update uv-build requirement.patch"; + url = "https://github.com/KapJI/capital-gains-calculator/commit/0222eafdcf1911f3e2fd781697dc53311f529f62.patch"; + hash = "sha256-L8jgrdA9t3x8mdaLmAuW6vFhHCLGA+0gQ/8j9EcYKhE="; + }) + ]; + build-system = with python3Packages; [ uv-build ];