1{ 2 lib, 3 buildPythonPackage, 4 cython, 5 fetchPypi, 6 numpy, 7 packaging, 8 pandas, 9 patsy, 10 pythonOlder, 11 scipy, 12 setuptools, 13 setuptools-scm, 14 stdenv, 15}: 16 17buildPythonPackage rec { 18 pname = "statsmodels"; 19 version = "0.14.2"; 20 pyproject = true; 21 22 disabled = pythonOlder "3.8"; 23 24 src = fetchPypi { 25 inherit pname version; 26 hash = "sha256-iQVQFHrTqBzaJPC6GlxAIa3BYBCAvQDhka581v7s1q0="; 27 }; 28 29 postPatch = '' 30 substituteInPlace pyproject.toml \ 31 --replace-fail "numpy>=2.0.0rc1,<3" "numpy" 32 ''; 33 34 build-system = [ 35 cython 36 numpy 37 scipy 38 setuptools 39 setuptools-scm 40 ]; 41 42 dependencies = [ 43 numpy 44 packaging 45 pandas 46 patsy 47 scipy 48 ]; 49 50 # Huge test suites with several test failures 51 doCheck = false; 52 53 pythonImportsCheck = [ "statsmodels" ]; 54 55 meta = with lib; { 56 description = "Statistical computations and models for use with SciPy"; 57 homepage = "https://www.github.com/statsmodels/statsmodels"; 58 changelog = "https://github.com/statsmodels/statsmodels/releases/tag/v${version}"; 59 license = licenses.bsd3; 60 # Fails at build time 61 broken = stdenv.isDarwin; 62 }; 63}