diff --git a/pkgs/development/python-modules/pytools/default.nix b/pkgs/development/python-modules/pytools/default.nix index 6f276f104f9e..7a4e11d7c030 100644 --- a/pkgs/development/python-modules/pytools/default.nix +++ b/pkgs/development/python-modules/pytools/default.nix @@ -2,30 +2,37 @@ lib, buildPythonPackage, fetchPypi, - pythonOlder, - decorator, numpy, platformdirs, - typing-extensions, pytestCheckHook, + pythonOlder, + setuptools, + typing-extensions, }: buildPythonPackage rec { pname = "pytools"; - version = "2024.1.6"; - format = "setuptools"; - disabled = pythonOlder "3.6"; + version = "2024.1.14"; + pyproject = true; + + disabled = pythonOlder "3.8"; src = fetchPypi { inherit pname version; - hash = "sha256-u9t1BrCWakShd8XlVWdb7OHmXhW7sRFPNwsiPgaTIrk="; + hash = "sha256-OeW7r4H6Qy5oi4LdCYAhLRj5eyPlGox6/nWSJJ/kCrE="; }; - propagatedBuildInputs = [ - decorator - numpy + build-system = [ setuptools ]; + + dependencies = [ platformdirs - ] ++ lib.optionals (pythonOlder "3.11") [ typing-extensions ]; + typing-extensions + ]; + + optional-dependencies = { + numpy = [ numpy ]; + # siphash = [ siphash ]; + }; nativeCheckInputs = [ pytestCheckHook ]; @@ -35,9 +42,18 @@ buildPythonPackage rec { "pytools.lex" ]; + disabledTests = [ + # siphash is not available + "test_class_hashing" + "test_dataclass_hashing" + "test_datetime_hashing" + "test_hash_function" + ]; + meta = { - homepage = "https://github.com/inducer/pytools/"; description = "Miscellaneous Python lifesavers"; + homepage = "https://github.com/inducer/pytools/"; + changelo = "https://github.com/inducer/pytools/releases/tag/v${version}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ artuuge ]; };