From bcf118d63d52feb1390d60672d9eb5c0349973ef Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sat, 22 Mar 2025 22:12:16 +0100 Subject: [PATCH] python313Packages.thefuzz: refactor --- .../python-modules/thefuzz/default.nix | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/pkgs/development/python-modules/thefuzz/default.nix b/pkgs/development/python-modules/thefuzz/default.nix index d307d5912b03..2f4613da9e00 100644 --- a/pkgs/development/python-modules/thefuzz/default.nix +++ b/pkgs/development/python-modules/thefuzz/default.nix @@ -6,12 +6,13 @@ pytestCheckHook, hypothesis, levenshtein, + setuptools, }: buildPythonPackage rec { pname = "thefuzz"; version = "0.22.1"; - format = "setuptools"; + pyproject = true; disabled = pythonOlder "3.7"; @@ -20,20 +21,27 @@ buildPythonPackage rec { hash = "sha256-cTgDmn7PVA2jI3kthZLvmQKx1563jBR9TyBmTeefNoA="; }; - propagatedBuildInputs = [ levenshtein ]; - # Skip linting postPatch = '' - substituteInPlace test_thefuzz.py --replace "import pycodestyle" "" + substituteInPlace test_thefuzz.py \ + --replace-fail "import pycodestyle" "" ''; - pythonImportsCheck = [ "thefuzz" ]; + build-system = [ setuptools ]; + + dependencies = [ levenshtein ]; nativeCheckInputs = [ hypothesis pytestCheckHook ]; + optional-dependencies = { + speedup = [ ]; + }; + + pythonImportsCheck = [ "thefuzz" ]; + disabledTests = [ # Skip linting "test_pep8_conformance"