From c7e3889914857c12695c88309a279191efc49b76 Mon Sep 17 00:00:00 2001 From: Ghislain Vaillant Date: Fri, 21 Aug 2026 14:39:09 +0200 Subject: machine-learning: python-geomstats: Fix build. * guix-science/packages/machine-learning.scm (python-geomstats) [arguments]<#:test-flags>: Ignore more flaky tests. <#:phases>: Add phase to rename trapz to trapezoid. --- guix-science/packages/machine-learning.scm | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/guix-science/packages/machine-learning.scm b/guix-science/packages/machine-learning.scm index da6c37f..d8cdd9b 100644 --- a/guix-science/packages/machine-learning.scm +++ b/guix-science/packages/machine-learning.scm @@ -557,6 +557,17 @@ length.") "-m" "not (slow or redundant)" ;; Flaky + (string-join (list + "--deselect=tests/tests_geomstats/test_datasets/test_prepare_graph_data.py" + "TestHyperbolicEmbedding" "test_embed") "::") + (string-join (list + "--deselect=tests/tests_geomstats/test_geometry/test_discrete_curves.py" + "TestReparametrizationAligner" + "test_align_in_same_fiber") "::") + (string-join (list + "--deselect=tests/tests_geomstats/test_geometry/test_product_hpd_and_siegel_disks.py" + "TestProductHPDMatricesAndSiegelDisksMetric" + "test_squared_dist_is_symmetric") "::") (string-join (list "--deselect=tests/tests_geomstats/test_geometry/test_hpd_matrices.py" "TestMatrixPower" "test_inverse_belongs") "::") @@ -566,8 +577,21 @@ length.") "test_parallel_transport_ivp_norm") "::") ;; Requires python-pykeops. "--ignore=tests/tests_geomstats/test_varifold.py" - ;; Requires jupyter kernel. - "--ignore=tests/tests_scripts/test_notebooks.py"))) + ;; Run unit tests only. + "tests/tests_geomstats") + #:phases + #~(modify-phases %standard-phases + ;; see + (add-after 'unpack 'rename-trapz-to-trapezoid + (lambda _ + (substitute* (list "geomstats/_backend/__init__.py" + "geomstats/_backend/autograd/__init__.py" + "geomstats/_backend/numpy/__init__.py" + "geomstats/_backend/pytorch/__init__.py" + "geomstats/geometry/functions.py" + "tests/tests_geomstats/test_geometry/data/functions.py") + (("trapz") + "trapezoid"))))))) (propagated-inputs (list python-autograd python-joblib python-matplotlib -- cgit v1.2.3