1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5 ipykernel,
6 ipywidgets,
7 jinja2,
8 jupyter,
9 numpy,
10 pandas,
11 pytestCheckHook,
12 pythonOlder,
13 setuptools,
14 traitlets,
15 wheel,
16}:
17
18buildPythonPackage rec {
19 pname = "pydeck";
20 version = "0.9.1";
21 format = "pyproject";
22
23 disabled = pythonOlder "3.7";
24
25 src = fetchPypi {
26 inherit pname version;
27 hash = "sha256-90R1rmN5UdY/LuWDJnV/jU+c2fKkV89ClQcVAD4stgU=";
28 };
29
30 # upstream has an invalid pyproject.toml
31 # https://github.com/visgl/deck.gl/issues/8469
32 postPatch = ''
33 rm pyproject.toml
34 '';
35
36 nativeBuildInputs = [
37 jinja2
38 jupyter
39 setuptools
40 wheel
41 ];
42
43 propagatedBuildInputs = [
44 jinja2
45 numpy
46 ];
47
48 optional-dependencies = {
49 carto = [
50 # pydeck-carto
51 ];
52 jupyter = [
53 ipykernel
54 ipywidgets
55 traitlets
56 ];
57 };
58
59 pythonImportsCheck = [ "pydeck" ];
60
61 nativeCheckInputs = [
62 pytestCheckHook
63 pandas
64 ]
65 ++ optional-dependencies.jupyter;
66
67 # tries to start a jupyter server
68 disabledTests = [ "test_nbconvert" ];
69
70 meta = with lib; {
71 homepage = "https://github.com/visgl/deck.gl/tree/master/bindings/pydeck";
72 description = "Large-scale interactive data visualization in Python";
73 maintainers = with maintainers; [ creator54 ];
74 license = licenses.asl20;
75 };
76}