diff --git a/pkgs/development/python-modules/bambi/default.nix b/pkgs/development/python-modules/bambi/default.nix index b6c2b0de7587..dd76021cab03 100644 --- a/pkgs/development/python-modules/bambi/default.nix +++ b/pkgs/development/python-modules/bambi/default.nix @@ -12,11 +12,14 @@ , pandas , pymc , scipy +, setuptools }: buildPythonPackage rec { pname = "bambi"; version = "0.10.0"; + format = "pyproject"; + disabled = pythonOlder "3.8"; src = fetchFromGitHub { @@ -26,6 +29,10 @@ buildPythonPackage rec { hash = "sha256-D04eTAlckEqgKA+59BRljlyneHYoqqZvLYmt/gBLHcU="; }; + nativeBuildInputs = [ + setuptools + ]; + propagatedBuildInputs = [ arviz formulae @@ -35,7 +42,9 @@ buildPythonPackage rec { scipy ]; - preCheck = ''export HOME=$(mktemp -d)''; + preCheck = '' + export HOME=$(mktemp -d) + ''; nativeCheckInputs = [ blackjax @@ -43,13 +52,24 @@ buildPythonPackage rec { numpyro pytestCheckHook ]; + disabledTests = [ - # attempt to fetch data: + # Tests require network access + "test_custom_prior" "test_data_is_copied" + "test_distributional_model" + "test_gamma_with_splines" + "test_non_distributional_model_with_categories" + "test_non_distributional_model" + "test_normal_with_splines" "test_predict_offset" + # Assertion issue + "test_custom_likelihood_function" ]; - pythonImportsCheck = [ "bambi" ]; + pythonImportsCheck = [ + "bambi" + ]; meta = with lib; { homepage = "https://bambinos.github.io/bambi";