1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 setuptools,
6 numpy,
7 pytestCheckHook,
8 pytest-cov,
9}:
10
11buildPythonPackage rec {
12 pname = "pyevtk";
13 version = "1.2.0";
14 pyproject = true;
15
16 src = fetchFromGitHub {
17 owner = "pyscience-projects";
18 repo = "pyevtk";
19 rev = "refs/tags/v${version}";
20 hash = "sha256-HrodoVxjREZiutgRJ3ZUrART29+gAZfpR9f4A4SRh4Q=";
21 };
22
23 postPatch = ''
24 substituteInPlace setup.py \
25 --replace-fail 'setup_requires=["pytest-runner"],' 'setup_requires=[],'
26 '';
27
28 build-system = [ setuptools ];
29 dependencies = [ numpy ];
30
31 nativeCheckInputs = [
32 pytestCheckHook
33 pytest-cov
34 ];
35
36 pythonImportsCheck = [ "pyevtk" ];
37
38 meta = {
39 description = "Exports data to binary VTK files for visualization/analysis";
40 homepage = "https://github.com/pyscience-projects/pyevtk";
41 changelog = "https://github.com/pyscience-projects/pyevtk/blob/${src.rev}/CHANGES.txt";
42 license = lib.licenses.bsd2;
43 maintainers = with lib.maintainers; [ sigmanificient ];
44 };
45}