linux_xanmod: 5.11.14 -> 5.11.15
[NixPkgs.git] / pkgs / development / python-modules / pyproj / default.nix
blob2f4f26f03b43e0edebf209137eacbe54829b2b90
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , python
5 , proj
6 , pythonOlder
7 , substituteAll
8 , cython
9 , pytestCheckHook
10 , mock
11 , certifi
12 , numpy
13 , shapely
14 , pandas
15 , xarray
18 buildPythonPackage rec {
19   pname = "pyproj";
20   version = "3.0.1";
21   disabled = pythonOlder "3.7";
23   src = fetchFromGitHub {
24     owner = "pyproj4";
25     repo = "pyproj";
26     rev = version;
27     sha256 = "1q1i1235cp3k32dpb11r7krx5rpqwszb89mrx85rflc1z5acaj58";
28   };
30   # force pyproj to use ${proj}
31   patches = [
32     (substituteAll {
33       src = ./001.proj.patch;
34       proj = proj;
35       projdev = proj.dev;
36     })
37   ];
39   nativeBuildInputs = [ cython ];
40   buildInputs = [ proj ];
42   propagatedBuildInputs = [
43      certifi
44   ];
46   checkInputs = [
47     pytestCheckHook
48     mock
49     numpy
50     shapely
51     pandas
52     xarray
53   ];
55   preCheck = ''
56     # We need to build extensions locally to run tests
57     ${python.interpreter} setup.py build_ext --inplace
58     cd test
59   '';
61   disabledTestPaths = [
62     "test_doctest_wrapper.py"
63     "test_datadir.py"
64   ];
66   disabledTests = [
67     # The following tests try to access network and end up with a URLError
68     "test__load_grid_geojson_old_file"
69     "test_get_transform_grid_list"
70     "test_get_transform_grid_list__area_of_use"
71     "test_get_transform_grid_list__bbox__antimeridian"
72     "test_get_transform_grid_list__bbox__out_of_bounds"
73     "test_get_transform_grid_list__contains"
74     "test_get_transform_grid_list__file"
75     "test_get_transform_grid_list__source_id"
76     "test_sync__area_of_use__list"
77     "test_sync__bbox__list"
78     "test_sync__bbox__list__exclude_world_coverage"
79     "test_sync__download_grids"
80     "test_sync__file__list"
81     "test_sync__source_id__list"
82     "test_sync_download"
83     "test_sync_download__directory"
84     "test_sync_download__system_directory"
85     "test_transformer_group__download_grids"
86   ];
88   meta = {
89     description = "Python interface to PROJ.4 library";
90     homepage = "https://github.com/pyproj4/pyproj";
91     license = with lib.licenses; [ isc ];
92     maintainers = with lib.maintainers; [ lsix ];
93   };