From d4e573cde41dd92d897c9bfaa46498aa10e460c2 Mon Sep 17 00:00:00 2001 From: Jonas Heinrich Date: Thu, 25 Aug 2022 13:10:44 +0200 Subject: [PATCH] transifex-client: Fix build --- pkgs/tools/text/transifex-client/default.nix | 32 ++++++++++++++------ pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 23 insertions(+), 11 deletions(-) diff --git a/pkgs/tools/text/transifex-client/default.nix b/pkgs/tools/text/transifex-client/default.nix index 1174c2f382e3..ae23e5775592 100644 --- a/pkgs/tools/text/transifex-client/default.nix +++ b/pkgs/tools/text/transifex-client/default.nix @@ -1,24 +1,36 @@ -{ lib, buildPythonApplication, fetchPypi -, python-slugify, requests, urllib3, six, setuptools, GitPython }: +{ lib +, buildPythonApplication +, fetchPypi +, python-slugify +, requests +, urllib3 +, six +, setuptools +, GitPython +, pythonRelaxDepsHook +}: buildPythonApplication rec { pname = "transifex-client"; version = "0.14.4"; - propagatedBuildInputs = [ - urllib3 requests python-slugify six setuptools GitPython - ]; - src = fetchPypi { inherit pname version; sha256 = "11dc95cefe90ebf0cef3749c8c7d85b9d389c05bd0e3389bf117685df562bd5c"; }; # https://github.com/transifex/transifex-client/issues/323 - prePatch = '' - substituteInPlace requirements.txt \ - --replace "python-slugify<5.0.0" "python-slugify" - ''; + nativeBuildInputs = [ pythonRelaxDepsHook ]; + pythonRelaxDeps = [ "python-slugify" ]; + + propagatedBuildInputs = [ + GitPython + python-slugify + requests + setuptools + six + urllib3 + ]; # Requires external resources doCheck = false; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 087d384479b7..b6ff5da1d143 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -11585,7 +11585,7 @@ with pkgs; transcrypt = callPackage ../applications/version-management/git-and-tools/transcrypt { }; - transifex-client = python3.pkgs.callPackage ../tools/text/transifex-client { }; + transifex-client = python39.pkgs.callPackage ../tools/text/transifex-client { }; translate-shell = callPackage ../applications/misc/translate-shell { };