From c30829cc0cd6b1fd7e6d4c03a20088089d1bc565 Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Fri, 7 Feb 2025 16:08:41 +0100 Subject: [PATCH 1/3] python312Packages.blackjax: 1.2.4 -> 1.2.5 Diff: https://github.com/blackjax-devs/blackjax/compare/refs/tags/1.2.4...1.2.5 Changelog: https://github.com/blackjax-devs/blackjax/releases/tag/1.2.5 --- pkgs/development/python-modules/blackjax/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/blackjax/default.nix b/pkgs/development/python-modules/blackjax/default.nix index 5b02bf3450d6..e89e390771a7 100644 --- a/pkgs/development/python-modules/blackjax/default.nix +++ b/pkgs/development/python-modules/blackjax/default.nix @@ -23,14 +23,14 @@ buildPythonPackage rec { pname = "blackjax"; - version = "1.2.4"; + version = "1.2.5"; pyproject = true; src = fetchFromGitHub { owner = "blackjax-devs"; repo = "blackjax"; tag = version; - hash = "sha256-qaQBbRAKExRHr4Uhm5/Q1Ydon6ePsjG2PWbwSdR9QZM="; + hash = "sha256-2GTjKjLIWFaluTjdWdUF9Iim973y81xv715xspghRZI="; }; build-system = [ setuptools-scm ]; From cf53cd618af9ec744e9deb57b127eb993ce847bc Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Fri, 7 Feb 2025 16:44:20 +0100 Subject: [PATCH 2/3] python312Packages.cvxpy: disable failing tests --- pkgs/development/python-modules/cvxpy/default.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkgs/development/python-modules/cvxpy/default.nix b/pkgs/development/python-modules/cvxpy/default.nix index de88b31cce3e..bd32bc8ebedb 100644 --- a/pkgs/development/python-modules/cvxpy/default.nix +++ b/pkgs/development/python-modules/cvxpy/default.nix @@ -75,6 +75,11 @@ buildPythonPackage rec { "test_diffcp_sdp_example" "test_huber" "test_partial_problem" + + # cvxpy.error.SolverError: Solver 'CVXOPT' failed. Try another solver, or solve with verbose=True for more information. + "test_oprelcone_1_m1_k3_complex" + "test_oprelcone_1_m3_k1_complex" + "test_oprelcone_2" ]; pythonImportsCheck = [ "cvxpy" ]; From 1bc4ebfb35a9f74f9b0d1d22bb3a76a47461239f Mon Sep 17 00:00:00 2001 From: Gaetan Lepage Date: Fri, 7 Feb 2025 17:13:40 +0100 Subject: [PATCH 3/3] python312Packages.qutip: add aarch64-linux to badPlatforms --- .../python-modules/qutip/default.nix | 21 ++++++++++--------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/pkgs/development/python-modules/qutip/default.nix b/pkgs/development/python-modules/qutip/default.nix index d5c0dea156b0..28d8d16087e7 100644 --- a/pkgs/development/python-modules/qutip/default.nix +++ b/pkgs/development/python-modules/qutip/default.nix @@ -17,6 +17,7 @@ # tests pytestCheckHook, pytest-rerunfailures, + writableTmpDirAsHomeHook, python, # optional-dependencies @@ -38,11 +39,12 @@ buildPythonPackage rec { hash = "sha256-5j47Wqt9i6vC3uwRzQ9+8pk+ENl5w6PvnP+830RLCls="; }; - postPatch = '' + postPatch = # build-time constriant, used to ensure forward and backward compat - substituteInPlace pyproject.toml setup.cfg \ - --replace-fail "numpy>=2.0.0" "numpy" - ''; + '' + substituteInPlace pyproject.toml setup.cfg \ + --replace-fail "numpy>=2.0.0" "numpy" + ''; build-system = [ cython_0 @@ -59,6 +61,7 @@ buildPythonPackage rec { nativeCheckInputs = [ pytestCheckHook pytest-rerunfailures + writableTmpDirAsHomeHook ] ++ lib.flatten (builtins.attrValues optional-dependencies); # QuTiP tries to access the home directory to create an rc file for us. @@ -66,7 +69,6 @@ buildPythonPackage rec { # This is due to the Cython-compiled modules not being in the correct location # of the source tree. preCheck = '' - export HOME=$(mktemp -d); export OMP_NUM_THREADS=$NIX_BUILD_CORES mkdir -p test && cd test ''; @@ -80,11 +82,6 @@ buildPythonPackage rec { pythonImportsCheck = [ "qutip" ]; - pytestFlagsArray = lib.optionals (stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isAarch64) [ - # Fatal Python error: Aborted - "--deselect=../tests/core/test_metrics.py::Test_hellinger_dist::test_monotonicity[25]" - ]; - optional-dependencies = { graphics = [ matplotlib ]; ipython = [ ipython ]; @@ -104,6 +101,10 @@ buildPythonPackage rec { # Tests fail at ~80% # ../tests/test_animation.py::test_result_state Fatal Python error: Aborted lib.systems.inspect.patterns.isDarwin + + # Several tests fail with a segfault + # ../tests/test_random.py::test_rand_super_bcsz[int-CSR-choi-None-rep(1)] Fatal Python error: Aborted + "aarch64-linux" ]; }; }