Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

python311Packages.scikit-survival: 0.21.0 -> 0.22.1; fix build #266019

Merged
merged 1 commit into from Nov 8, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 13 additions & 5 deletions pkgs/development/python-modules/scikit-survival/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@

buildPythonPackage rec {
pname = "scikit-survival";
version = "0.21.0";
format = "setuptools";
version = "0.22.1";
pyproject = true;

src = fetchPypi {
inherit pname version;
hash = "sha256-rcdEtlmD3O2BQuwxRlOJ/HOEBdWJBRJR5UR6rZoeArw=";
hash = "sha256-Ft0Hg5iF9Sb9VSOsFMgfAvc4Nsam216kzt5Xv2iykv8=";
};

nativeBuildInputs = [
Expand All @@ -45,6 +45,11 @@ buildPythonPackage rec {

nativeCheckInputs = [ pytestCheckHook ];

# treat numpy versions as lower bounds, same as setuptools build
postPatch = ''
sed -i 's/numpy==/numpy>=/' pyproject.toml
'';

# Hack needed to make pytest + cython work
# https://github.com/NixOS/nixpkgs/pull/82410#issuecomment-827186298
preCheck = ''
Expand All @@ -63,10 +68,13 @@ buildPythonPackage rec {
"test_pandas_inputs"
"test_survival_svm"
"test_tree"
];
] ++ lib.optional (stdenv.isDarwin && stdenv.isAarch64)
# floating point mismatch on aarch64
# 27079905.88052468 to far from 27079905.880496684
"test_coxnet"
;

meta = with lib; {
broken = (stdenv.isLinux && stdenv.isAarch64);
description = "Survival analysis built on top of scikit-learn";
homepage = "https://github.com/sebp/scikit-survival";
license = licenses.gpl3Only;
Expand Down