about summary refs log tree commit diff
path: root/pkgs/development/python-modules/hyppo/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/python-modules/hyppo/default.nix')
-rw-r--r--pkgs/development/python-modules/hyppo/default.nix61
1 files changed, 38 insertions, 23 deletions
diff --git a/pkgs/development/python-modules/hyppo/default.nix b/pkgs/development/python-modules/hyppo/default.nix
index 8b2d73f68c5a..5288be1c30a3 100644
--- a/pkgs/development/python-modules/hyppo/default.nix
+++ b/pkgs/development/python-modules/hyppo/default.nix
@@ -1,49 +1,64 @@
-{ lib
-, buildPythonPackage
-, pythonOlder
-, fetchFromGitHub
-, pytestCheckHook
-, autograd
-, numba
-, numpy
-, scikit-learn
-, scipy
-, matplotlib
-, seaborn
+{
+  lib,
+  autograd,
+  buildPythonPackage,
+  fetchFromGitHub,
+  future,
+  matplotlib,
+  numba,
+  numpy,
+  pytestCheckHook,
+  pythonOlder,
+  scikit-learn,
+  scipy,
+  seaborn,
+  setuptools,
 }:
 
 buildPythonPackage rec {
   pname = "hyppo";
-  version = "0.4.0";
-  format = "setuptools";
+  version = "0.5.1";
+  pyproject = true;
 
-  disabled = pythonOlder "3.6";
+  disabled = pythonOlder "3.8";
 
   src = fetchFromGitHub {
     owner = "neurodata";
-    repo = pname;
+    repo = "hyppo";
     rev = "refs/tags/v${version}";
-    hash = "sha256-QRE3oSxTEobTQ/7DzCAUOdjzIZmWUn9bgPmJWj6JuZg=";
+    hash = "sha256-bYxqYSOOifQE3gbw8vNk/A13D5TPx7ERSgFvRHMXKGM=";
   };
 
-  propagatedBuildInputs = [
+  # some of the doctests (4/21) are broken, e.g. unbound variables, nondeterministic with insufficient tolerance, etc.
+  # (note upstream's .circleci/config.yml only tests test_*.py files despite their pytest.ini adding --doctest-modules)
+  postPatch = ''
+    substituteInPlace pytest.ini --replace-fail "addopts = --doctest-modules" ""
+  '';
+
+  build-system = [ setuptools ];
+
+  dependencies = [
     autograd
+    future
     numba
     numpy
     scikit-learn
     scipy
   ];
 
-  nativeCheckInputs = [ pytestCheckHook matplotlib seaborn ];
-  disabledTestPaths = [
-    "docs"
-    "benchmarks"
-    "examples"
+  nativeCheckInputs = [
+    pytestCheckHook
+    matplotlib
+    seaborn
+  ];
+  pytestFlagsArray = [
+    "hyppo"
   ];
 
   meta = with lib; {
     homepage = "https://github.com/neurodata/hyppo";
     description = "Python package for multivariate hypothesis testing";
+    changelog = "https://github.com/neurodata/hyppo/releases/tag/v${version}";
     license = licenses.mit;
     maintainers = with maintainers; [ bcdarwin ];
   };