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
83
|
{
lib,
stdenv,
python,
buildPythonPackage,
fetchFromGitHub,
cython,
pybind11,
tiledb,
numpy,
wheel,
isPy3k,
setuptools-scm,
psutil,
pandas,
cmake,
ninja,
scikit-build-core,
packaging,
pytest,
hypothesis,
pyarrow,
}:
buildPythonPackage rec {
pname = "tiledb";
version = "0.36.0";
pyproject = true;
src = fetchFromGitHub {
owner = "TileDB-Inc";
repo = "TileDB-Py";
tag = version;
hash = "sha256-zkooZuy6BAV2aR5PQ67/tiX/dARQw5WDNQVqlrs/U2s=";
};
build-system = [
cython
pybind11
setuptools-scm
scikit-build-core
packaging
cmake
ninja
];
buildInputs = [ tiledb ];
propagatedBuildInputs = [
numpy
];
nativeCheckInputs = [
psutil
# optional
pandas
pytest
hypothesis
pyarrow
];
TILEDB_PATH = tiledb;
disabled = !isPy3k; # Not bothering with python2 anymore
dontUseCmakeConfigure = true;
# We have to run pytest from a diffferent directory to force it to import tiledb from $out
# otherwise it cannot be imported because extension modules are not compiled in sources
checkPhase = ''
pushd "$TMPDIR"
${python.interpreter} -m pytest --pyargs tiledb${lib.optionalString stdenv.isDarwin " -k 'not test_ctx_thread_cleanup and not test_array'"}
popd
'';
pythonImportsCheck = [ "tiledb" ];
meta = {
description = "Python interface to the TileDB storage manager";
homepage = "https://github.com/TileDB-Inc/TileDB-Py";
license = lib.licenses.mit;
};
}
|