diff --git a/pkgs/development/python-modules/jaraco_functools/2.nix b/pkgs/development/python-modules/jaraco_functools/2.nix new file mode 100644 index 000000000000..e0bbde47d250 --- /dev/null +++ b/pkgs/development/python-modules/jaraco_functools/2.nix @@ -0,0 +1,25 @@ +{ lib, buildPythonPackage, fetchPypi +, setuptools_scm +, more-itertools, backports_functools_lru_cache }: + +buildPythonPackage rec { + pname = "jaraco.functools"; + version = "2.0"; + + src = fetchPypi { + inherit pname version; + sha256 = "0ickpwvvdrlbm477gdzfjfcbgmfia9ksm9a3i3pbx9xia97r9fim"; + }; + + propagatedBuildInputs = [ more-itertools backports_functools_lru_cache ]; + + doCheck = false; + + buildInputs = [ setuptools_scm ]; + + meta = with lib; { + description = "Additional functools in the spirit of stdlib's functools"; + homepage = "https://github.com/jaraco/jaraco.functools"; + license = licenses.mit; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index c5d030e0697f..bca892f06c3e 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -7037,7 +7037,10 @@ in { morphys = callPackage ../development/python-modules/morphys { }; - jaraco_functools = callPackage ../development/python-modules/jaraco_functools { }; + jaraco_functools = if pythonOlder "3.6" then + callPackage ../development/python-modules/jaraco_functools/2.nix { } + else + callPackage ../development/python-modules/jaraco_functools { }; jaraco_classes = callPackage ../development/python-modules/jaraco_classes { };