diff --git a/pkgs/development/python-modules/pygeos/default.nix b/pkgs/development/python-modules/pygeos/default.nix index c6ce198ee26d..54107db9ef60 100644 --- a/pkgs/development/python-modules/pygeos/default.nix +++ b/pkgs/development/python-modules/pygeos/default.nix @@ -14,21 +14,17 @@ buildPythonPackage rec { src = fetchPypi { inherit pname version; - sha256 = "sha256-MPvBf2SEQgC4UTO4hfz7ZVQbh3lTH270+P5GfT+6diM="; + hash = "sha256-MPvBf2SEQgC4UTO4hfz7ZVQbh3lTH270+P5GfT+6diM="; }; - patches = [ - # Adapt https://github.com/shapely/shapely/commit/4889bd2d72ff500e51ba70d5b954241878349562, - # backporting to pygeos - ./fix-for-geos-3-11.patch - ]; - nativeBuildInputs = [ geos # for geos-config cython ]; - propagatedBuildInputs = [ numpy ]; + propagatedBuildInputs = [ + numpy + ]; # The cythonized extensions are required to exist in the pygeos/ directory # for the package to function. Therefore override of buildPhase was @@ -42,11 +38,14 @@ buildPythonPackage rec { pytestCheckHook ]; - pythonImportsCheck = [ "pygeos" ]; + pythonImportsCheck = [ + "pygeos" + ]; meta = with lib; { - description = "Wraps GEOS geometry functions in numpy ufuncs."; + description = "Wraps GEOS geometry functions in numpy ufuncs"; homepage = "https://github.com/pygeos/pygeos"; + changelog = "https://github.com/pygeos/pygeos/blob/${version}/CHANGELOG.rst"; license = licenses.bsd3; maintainers = with maintainers; [ nialov ]; }; diff --git a/pkgs/development/python-modules/pygeos/fix-for-geos-3-11.patch b/pkgs/development/python-modules/pygeos/fix-for-geos-3-11.patch deleted file mode 100644 index fe81c0769c18..000000000000 --- a/pkgs/development/python-modules/pygeos/fix-for-geos-3-11.patch +++ /dev/null @@ -1,29 +0,0 @@ -From ea82dbefeb573150935eb78a6916813775512e76 Mon Sep 17 00:00:00 2001 -From: Joris Van den Bossche -Date: Tue, 26 Apr 2022 22:17:00 +0200 -Subject: [PATCH] TST: fix tests for GEOS main (#1357) (backported for nixpkgs) - ---- - pygeos/tests/test_constructive.py | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) - -diff --git a/pygeos/tests/test_constructive.py b/pygeos/tests/test_constructive.py -index 87c0a9f..b3459d1 100644 ---- a/pygeos/tests/test_constructive.py -+++ b/pygeos/tests/test_constructive.py -@@ -48,7 +48,11 @@ def test_no_args_array(geometry, func): - @pytest.mark.parametrize("geometry", all_types) - @pytest.mark.parametrize("func", CONSTRUCTIVE_FLOAT_ARG) - def test_float_arg_array(geometry, func): -- if func is pygeos.offset_curve and pygeos.get_type_id(geometry) not in [1, 2]: -+ if ( -+ func is pygeos.offset_curve -+ and pygeos.get_type_id(geometry) not in [1, 2] -+ and pygeos.geos_version < (3, 11, 0) -+ ): - with pytest.raises(GEOSException, match="only accept linestrings"): - func([geometry, geometry], 0.0) - return --- -2.36.1 -