Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / python-modules / mnist / default.nix
blob2d0b158534bf2b8e2e45614a66736f54b57ad8d9
1 { buildPythonPackage, fetchFromGitHub, isPy27, lib, mock, numpy, pytestCheckHook
2 }:
4 buildPythonPackage rec {
5   pname = "mnist";
6   version = "0.2.2";
8   src = fetchFromGitHub {
9     owner = "datapythonista";
10     repo = "mnist";
11     rev = "${pname}-${version}";
12     sha256 = "17r37pbxiv5dw857bmg990x836gq6sgww069w3q5jjg9m3xdm7dh";
13   };
15   propagatedBuildInputs = [ numpy ] ++ lib.optional isPy27 mock;
17   nativeCheckInputs = [ pytestCheckHook ];
19   dontUseSetuptoolsCheck = true;
21   # disable tests which fail due to socket related errors
22   disabledTests = [
23     "test_test_images_has_right_size"
24     "test_test_labels_has_right_size"
25     "test_train_images_has_right_size"
26     "test_train_labels_has_right_size"
27   ];
29   meta = with lib; {
30     description = "Python utilities to download and parse the MNIST dataset";
31     homepage = "https://github.com/datapythonista/mnist";
32     license = licenses.bsd3;
33     maintainers = with maintainers; [ dmrauh ];
34   };