python310Packages.editdistance: disable on older Python releases

This commit is contained in:
Fabian Affolter
2022-10-30 22:00:28 +01:00
committed by GitHub
parent 1a6c366b80
commit d1e9d8fb2e
@@ -3,29 +3,38 @@
, fetchFromGitHub
, pytestCheckHook
, cython
, pythonOlder
}:
buildPythonPackage rec {
pname = "editdistance";
version = "0.6.1";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "roy-ht";
repo = pname;
rev = "v${version}";
sha256 = "sha256-c0TdH1nJAKrepatCSCTLaKsDv9NKruMQadCjclKGxBw=";
hash = "sha256-c0TdH1nJAKrepatCSCTLaKsDv9NKruMQadCjclKGxBw=";
};
nativeBuildInputs = [ cython ];
nativeBuildInputs = [
cython
];
preBuild = ''
cythonize --inplace editdistance/bycython.pyx
'';
checkInputs = [ pytestCheckHook ];
checkInputs = [
pytestCheckHook
];
pythonImportsCheck = [ "editdistance" ];
pythonImportsCheck = [
"editdistance"
];
meta = with lib; {
description = "Python implementation of the edit distance (Levenshtein distance)";