1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
|
{
lib,
stdenv,
buildPythonPackage,
fetchFromGitHub,
# build-system
flit,
# dependencies
attrs,
click,
pydantic,
pyproj,
# tests
mercantile,
rasterio,
pytestCheckHook,
versionCheckHook,
}:
buildPythonPackage rec {
pname = "morecantile";
version = "6.2.0";
pyproject = true;
src = fetchFromGitHub {
owner = "developmentseed";
repo = "morecantile";
tag = version;
hash = "sha256-ohTSgkjgaANS/Pli4fao+THA4ltts6svj5CdJEgorz0=";
};
build-system = [ flit ];
dependencies = [
attrs
click
pydantic
pyproj
];
nativeCheckInputs = [
mercantile
pytestCheckHook
rasterio
versionCheckHook
];
disabledTests = [
# AssertionError CLI exists with non-zero error code
# This is a regression introduced by https://github.com/NixOS/nixpkgs/pull/448189
"test_cli_shapes"
"test_cli_shapesWGS84"
"test_cli_strict_overlap_contain"
"test_cli_tiles_bad_bounds"
"test_cli_tiles_geosjon"
"test_cli_tiles_implicit_stdin"
"test_cli_tiles_multi_bounds"
"test_cli_tiles_multi_bounds_seq"
"test_cli_tiles_ok"
"test_cli_tiles_points"
"test_cli_tiles_seq"
]
++ lib.optionals stdenv.hostPlatform.isDarwin [
# https://github.com/developmentseed/morecantile/issues/156
"test_tiles_when_tms_bounds_and_provided_bounds_cross_antimeridian"
];
pythonImportsCheck = [ "morecantile" ];
meta = {
description = "Construct and use map tile grids in different projection";
homepage = "https://developmentseed.org/morecantile";
downloadPage = "https://github.com/developmentseed/morecantile";
changelog = "https://github.com/developmentseed/morecantile/releases/tag/${src.tag}";
license = lib.licenses.mit;
teams = [ lib.teams.geospatial ];
mainProgram = "morecantile";
};
}
|