lol

Merge pull request #211217 from nialov/fix-pygeos-version-0.14

python3Packages.pygeos: fix version 0.14 build

authored by

Fabian Affolter and committed by
GitHub
11d29ac9 d126d172

+9 -39
+9 -10
pkgs/development/python-modules/pygeos/default.nix
··· 14 14 15 15 src = fetchPypi { 16 16 inherit pname version; 17 - sha256 = "sha256-MPvBf2SEQgC4UTO4hfz7ZVQbh3lTH270+P5GfT+6diM="; 17 + hash = "sha256-MPvBf2SEQgC4UTO4hfz7ZVQbh3lTH270+P5GfT+6diM="; 18 18 }; 19 19 20 - patches = [ 21 - # Adapt https://github.com/shapely/shapely/commit/4889bd2d72ff500e51ba70d5b954241878349562, 22 - # backporting to pygeos 23 - ./fix-for-geos-3-11.patch 24 - ]; 25 - 26 20 nativeBuildInputs = [ 27 21 geos # for geos-config 28 22 cython 29 23 ]; 30 24 31 - propagatedBuildInputs = [ numpy ]; 25 + propagatedBuildInputs = [ 26 + numpy 27 + ]; 32 28 33 29 # The cythonized extensions are required to exist in the pygeos/ directory 34 30 # for the package to function. Therefore override of buildPhase was ··· 42 38 pytestCheckHook 43 39 ]; 44 40 45 - pythonImportsCheck = [ "pygeos" ]; 41 + pythonImportsCheck = [ 42 + "pygeos" 43 + ]; 46 44 47 45 meta = with lib; { 48 - description = "Wraps GEOS geometry functions in numpy ufuncs."; 46 + description = "Wraps GEOS geometry functions in numpy ufuncs"; 49 47 homepage = "https://github.com/pygeos/pygeos"; 48 + changelog = "https://github.com/pygeos/pygeos/blob/${version}/CHANGELOG.rst"; 50 49 license = licenses.bsd3; 51 50 maintainers = with maintainers; [ nialov ]; 52 51 };
-29
pkgs/development/python-modules/pygeos/fix-for-geos-3-11.patch
··· 1 - From ea82dbefeb573150935eb78a6916813775512e76 Mon Sep 17 00:00:00 2001 2 - From: Joris Van den Bossche <jorisvandenbossche@gmail.com> 3 - Date: Tue, 26 Apr 2022 22:17:00 +0200 4 - Subject: [PATCH] TST: fix tests for GEOS main (#1357) (backported for nixpkgs) 5 - 6 - --- 7 - pygeos/tests/test_constructive.py | 6 +++++- 8 - 1 file changed, 5 insertions(+), 1 deletion(-) 9 - 10 - diff --git a/pygeos/tests/test_constructive.py b/pygeos/tests/test_constructive.py 11 - index 87c0a9f..b3459d1 100644 12 - --- a/pygeos/tests/test_constructive.py 13 - +++ b/pygeos/tests/test_constructive.py 14 - @@ -48,7 +48,11 @@ def test_no_args_array(geometry, func): 15 - @pytest.mark.parametrize("geometry", all_types) 16 - @pytest.mark.parametrize("func", CONSTRUCTIVE_FLOAT_ARG) 17 - def test_float_arg_array(geometry, func): 18 - - if func is pygeos.offset_curve and pygeos.get_type_id(geometry) not in [1, 2]: 19 - + if ( 20 - + func is pygeos.offset_curve 21 - + and pygeos.get_type_id(geometry) not in [1, 2] 22 - + and pygeos.geos_version < (3, 11, 0) 23 - + ): 24 - with pytest.raises(GEOSException, match="only accept linestrings"): 25 - func([geometry, geometry], 0.0) 26 - return 27 - -- 28 - 2.36.1 29 -