about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/hickle/default.nix
blob: 6fcb1d166ac9384b73d2c6f448a14ec826fc7b16 (plain) (blame)
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
{ buildPythonPackage
, fetchPypi
, pythonOlder
, h5py
, numpy
, dill
, astropy
, scipy
, pandas
, pytestCheckHook
, lib
}:

buildPythonPackage rec {
  pname = "hickle";
  version = "5.0.2";
  format = "setuptools";

  disabled = pythonOlder "3.5";

  src = fetchPypi {
    inherit pname version;
    hash = "sha256-2+7OF/a89jK/zLhbk/Q2A+zsKnfRbq3YMKGycEWsLEQ=";
  };

  postPatch = ''
    substituteInPlace tox.ini --replace "--cov=./hickle" ""
  '';

  propagatedBuildInputs = [ h5py numpy dill ];

  nativeCheckInputs = [
    pytestCheckHook
    scipy
    pandas
    astropy
  ];

  pythonImportsCheck = [ "hickle" ];

  disabledTests = [
    # broken in 5.0.2 with recent NumPy
    # see https://github.com/telegraphic/hickle/issues/174
    "test_scalar_compression"
    # broken in 5.0.2 with python 3.11
    # see https://github.com/telegraphic/hickle/issues/169
    "test_H5NodeFilterProxy"
  ];

  meta = {
    description = "Serialize Python data to HDF5";
    homepage = "https://github.com/telegraphic/hickle";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [ bcdarwin ];
  };
}